revert tangram lib to fix crashes in ITC 18/133918/1 accepted/tizen/3.0/common/20170616.064108 accepted/tizen/3.0/mobile/20170614.223712 accepted/tizen/3.0/wearable/20170614.223715 submit/tizen_3.0/20170614.063736
authorjomui <jongmun.woo@samsung.com>
Wed, 14 Jun 2017 04:38:20 +0000 (13:38 +0900)
committerjomui <jongmun.woo@samsung.com>
Wed, 14 Jun 2017 04:38:36 +0000 (13:38 +0900)
Signed-off-by: jomui <jongmun.woo@samsung.com>
Change-Id: Ic42f999b900043005f02672c339705a2ae580f3f

24 files changed:
lib/aarch64/libtangram.so
lib/arm/libtangram.so
lib/i586/libtangram.so
lib/x86_64/libtangram.so
packaging/maps-plugin-mapzen.spec
scenes/bubble-wrap/bubble-wrap.yaml
scenes/bubble-wrap/images/bubble-wrap@2x.png [deleted file]
scenes/bubble-wrap/images/poi_icons_18@2x.png [new file with mode: 0644]
scenes/walkabout-style/images/draw-test10.jpg [deleted file]
scenes/walkabout-style/images/draw-test8.jpg [new file with mode: 0644]
scenes/walkabout-style/images/draw-test9.jpg [new file with mode: 0644]
scenes/walkabout-style/images/poi_icons_18@2x.png [new file with mode: 0644]
scenes/walkabout-style/images/relief-shading-environment-map.jpg [new file with mode: 0644]
scenes/walkabout-style/walkabout-style.yaml
src/mapzen/mapzen_api.cpp
src/mapzen/tangram/ease.h [new file with mode: 0644]
src/mapzen/tangram/platform.h
src/mapzen/tangram/platform_tizen.h
src/mapzen/tangram/properties.h [moved from src/mapzen/tangram/data/properties.h with 95% similarity]
src/mapzen/tangram/tangram.h
src/mapzen/tangram/types.h [moved from src/mapzen/tangram/util/types.h with 100% similarity]
src/mapzen/tangram/urlClient.h [deleted file]
src/mapzen/tangram_view.cpp
src/mapzen/tangram_view.hpp

index edfa8fc..e614b9f 100755 (executable)
Binary files a/lib/aarch64/libtangram.so and b/lib/aarch64/libtangram.so differ
index 3673727..86d7b54 100755 (executable)
Binary files a/lib/arm/libtangram.so and b/lib/arm/libtangram.so differ
index 30fef8b..9956866 100755 (executable)
Binary files a/lib/i586/libtangram.so and b/lib/i586/libtangram.so differ
index 6fcfdb1..9e4f212 100755 (executable)
Binary files a/lib/x86_64/libtangram.so and b/lib/x86_64/libtangram.so differ
index 578b306..f2a3a59 100644 (file)
@@ -1,6 +1,6 @@
 Name:       maps-plugin-mapzen
 Summary:    Tizen Mapzen Maps Plug-in Library
-Version:    0.0.2
+Version:    0.0.3
 Release:    1
 Group:      Location/Libraries
 License:    Apache-2.0
index 101ad3d..8da7cb4 100644 (file)
@@ -1,10 +1,6 @@
 Author: Geraldine Sarmiento, Nathaniel V. Kelso, Patricio Gonzalez Vivo, Brett Camper, Peter Richardson
 
 global:
-    # Sign up for a Mapzen API key to enjoy higher rate limits
-    # https://mapzen.com/documentation/overview/#developer-accounts-and-api-keys
-    sdk_mapzen_api_key: ''     # set this value to your Mapzen API key
-
     #ux/ui
     ux_language: false             # l10n language code, trusting OSM in v0.10 tiles, fixed in v1.0 tiles
     ux_language_fallback: false    # l10n language code, trusting OSM in v0.10 tiles, fixed in v1.0 tiles
@@ -13,20 +9,6 @@ global:
             // if a ux_langauge has been defined use that, else if there is feature name in the fallback_ux_language then use that, else use the feature's default name in the local language
             return (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature.name;
         }
-    ux_language_text_source_boundary_lines: |
-        function() {
-            var right = (global.ux_language && feature['name:right:'+global.ux_language]) || (global.ux_language_fallback && feature['name:right:'+global.ux_language_fallback]) || feature['name:right'];
-            var left = (global.ux_language && feature['name:left:'+global.ux_language]) || (global.ux_language_fallback && feature['name:left:'+global.ux_language_fallback]) || feature['name:left'];
-            if( right && left ) {
-                //if( right.includes(' ') || left.includes(' ') ) {
-                    return left + " - " + right;
-                //} else {
-                //    return right + '\n' + left;
-                //}
-            } else {
-                return (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature.name;
-            }
-        }
     ux_language_text_source_short: |
         function() {
             return (global.ux_language && feature['name:short:'+global.ux_language]) || (global.ux_language_fallback && feature['name:short:'+global.ux_language_fallback]) || feature['name:short'];
@@ -60,53 +42,35 @@ global:
     ux_language_text_source_ocean: |
         function() {
             var name = (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature['name'] || '';
-            name = name.split(' ').join('\n');
             return name.split('').join('  ');
         }
     ux_language_text_source_sea: |
         function() {
             var name = (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature['name'] || '';
-            name = name.split(' ').join('\n');
             return name.split('').join(' ');
         }
-    ux_language_text_source_continent_stacked_only: |
-        function() {
-            var name = (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature['name'] || '';
-            return name.split(' ').join('\n');
-        }
     ux_language_text_source_continent: |
         function() {
             var name = (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature['name'] || '';
-            name = name.split(' ').join('\n');
             return name.split('').join(' ');
         }
     ux_language_text_source_road_ref_and_name: |
         function() {
-            // if a ux_langauge has been defined use that, else if there is feature name in the fallback_ux_language then use that, else use the feature's default name in the local language
-            return (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature.name;
-
-            /*
             var name = (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature['name'];
             if(feature.ref && name) {
                 return (feature.ref + ' ' + name);
             } else {
                 return name;
             }
-            */
         }
     ux_language_text_source_road_ref_and_name_short: |
         function() {
-            // if a ux_langauge has been defined use that, else if there is feature name in the fallback_ux_language then use that, else use the feature's default name in the local language
-            return (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature.name;
-
-            /*
             var name = (global.ux_language && feature['name:'+global.ux_language]) || (global.ux_language_fallback && feature['name:'+global.ux_language_fallback]) || feature['name'];
             if (feature.ref && (feature.ref.length < 6) && name) {
                 return feature.ref + ' ' + name;
             } else {
                 return name;
             }
-            */
         }
     ux_language_text_source_piste_advanced: |
         function() {
@@ -189,66 +153,55 @@ global:
     # or app logic sets other booleans that triggers auto behavior later
     sdk_transit_overlay: false
     #
-    # SHIELDS
-    sdk_shield_color: [0.506,0.192,0.169]
-    sdk_shield_text_color: white
-    #
-    # enable interactivity for key features
-    sdk_interactive: false
-    #
     # default order for basemap features
     feature_order: function() { return feature.sort_rank; }
     #
     #label visibility
-    text_visible_continent:         true
-    text_visible_admin:             true
-    text_visible_populated_places:  true
-    icon_visible_populated_places:  true
-    text_visible_neighbourhoods:    true
-    text_visible_neighbourhoods_e:  true
-    text_visible_building:          true     # false for default
-    text_visible_address:           true     # false for default
-    text_visible_water_labels:      true
-    text_visible_island:            true
-    label_visible_landuse_green:    true
-    icon_visible_landuse_green:     true     # needs work
-    text_visible_landuse_green:     true
-    icon_size_green:                [[13, 14px], [16, 18px], [18, 19px]]    # 0px for no, default, more  [[13, 14px], [16, 18px], [18, 19px]]
-    icon_size_green_l:              [[13, 14px], [16, 18px], [18, 19px]]    # 0px for no, default, more  [[14,24px],[16,32px]]
-    label_visible_poi_landuse:      true
-    icon_visible_poi_landuse:       true     # false for default
-    text_visible_poi_landuse:       true     # false for default
-    label_visible_poi_landuse_e:    true
-    icon_visible_poi_landuse_e:     true     # false for default
-    text_visible_poi_landuse_e:    true
-    text_visible_landuse_generic:   true     # false for default
-    label_visible_station:          true     # false for default
-    icon_visible_station:           true     # false for default
-    text_visible_station:           true     # false for default
-    text_visible_highway:           true
-    text_visible_highway_e:         true     # false for default, false for more
-    text_visible_trunk_primary:     true
-    text_visible_trunk_primary_route: true        # true by default
-    text_visible_trunk_primary_e2:  true     # false for default, false for more
-    text_visible_trunk_primary_e:   true     # false for default, false for more
-    text_visible_secondary:         true
-    text_visible_secondary_e:       true     # false for default, false for more
-    text_visible_tertiary:          true
-    text_visible_tertiary_e:        true     # false for default, false for more
-    text_visible_minor_road:        true
-    text_visible_minor_road_e:      true
-    text_visible_service_road:      true
-    text_visible_path:              true
-    text_visible_piste:             true
-    text_visible_steps:             true
-    text_visible_aerialway:         true
-    text_visible_airport_gate:      true
-    sdk_road_shields:               true
-    text_visible_exits:             true
-    text_visible_exits_e:           true     # false for default, false for more
+    text_visible_continent: true
+    text_visible_admin: true
+    text_visible_populated_places: true
+    icon_visible_populated_places: true
+    text_visible_neighbourhoods: true
+    text_visible_neighbourhoods_e: true
+    text_visible_building: true
+    text_visible_address: true
+    text_visible_water_labels: true
+    text_visible_island: true
+    label_visible_landuse_green: true
+    icon_visible_landuse_green: true
+    text_visible_landuse_green: true
+    label_visible_poi_landuse: true
+    icon_visible_poi_landuse: true
+    text_visible_poi_landuse: true
+    label_visible_poi_landuse_e: true
+    icon_visible_poi_landuse_e: true
+    text_visible_poi_landuse_e: true
+    text_visible_landuse_generic: true
+    label_visible_station: true
+    icon_visible_station: true
+    text_visible_station: true
+    text_visible_highway: true
+    text_visible_highway_e: true
+    text_visible_trunk_primary: true
+    text_visible_trunk_primary_e2: true
+    text_visible_trunk_primary_e: true
+    text_visible_secondary: true
+    text_visible_secondary_e: true
+    text_visible_tertiary: true
+    text_visible_tertiary_e: true
+    text_visible_minor_road: true
+    text_visible_minor_road_e: true
+    text_visible_service_road: true
+    text_visible_path: true
+    text_visible_piste: true
+    text_visible_steps: true
+    text_visible_aerialway: true
+    text_visible_airport_gate: true
+    text_visible_shields: true
+    text_visible_exits: true
     #
     #label styling
-    text_fill: [0.300, 0.300, 0.300]         # BLACK
+    text_fill: black                         # BLACK
     text_fill2: '#555'                       # WHITE
     text_fill_road_e: '#555'                 # WHITE
     text_fill_exits: [0.920,0.398,0.340]     # motorway junctions, highway_casing1
@@ -328,7 +281,7 @@ global:
     #
     #boundaries
     country_boundary: [1.0,1.0,1.0]
-    region_boundary: [0.96,0.96,0.96]
+    region_boundary: [1.0,1.0,1.0]
     subregion_boundary: '#bbb'
     city_wall: [0.682,0.682,0.682]
     retaining_wall: [0.827,0.808,0.780]
@@ -337,7 +290,7 @@ global:
     #
     #landuse
     water1: [0.83, 0.83, 0.83]              # water
-    water2: [0.83, 0.83, 0.83]              # playa
+    water2: [.75,.75,.75]                   # playa
     water1_o: '#9dc3de'                     # water stroke
     water2_o: '#9dc3de'                     # water stroke 2
     earth1: [0.870,0.870,0.870]             # land color, used to set scene background color
@@ -416,344 +369,182 @@ global:
     building2: [.860, .860, .860]           # building stroke
     building_o:  5                          # building stroke order
     building_e: true                        # building stroke order early
-    sdk_building_extrude: true              # building extrusion toggle
+    building_extrude: true                  # building extrusion toggle
     building_extrude_height: |              # building extrude height logic
         function() { return feature.height || 20; }
 
+
 textures:
     pois:
-        url: images/bubble-wrap@2x.png
-        #url: https://raw.githubusercontent.com/tangrams/bubble-wrap/gh-pages/images/bubble-wrap%402x.png
+        url: images/poi_icons_18@2x.png
         filtering: mipmap
         sprites:
             # define sprites: [x origin, y origin, width, height]
-            'US:CA-1char': [350, 694, 82, 90]
-            'US:CA-2char': [826, 694, 92, 92]
-            'US:CA-3char': [706, 694, 112, 92]
-            'US:CA-4char': [574, 694, 124, 92]
-            'US:CA-5char': [438, 694, 128, 92]
-            'US:I-1char': [686, 790, 90, 100]
-            'US:I-2char': [288, 894, 100, 100]
-            'US:I-3char': [148, 894, 134, 100]
-            'US:I-4char': [0, 894, 140, 100]
-            'US:I-5char': [784, 790, 152, 100]
-            'US:NY-1char': [560, 602, 72, 88]
-            'US:NY-2char': [812, 510, 88, 88]
-            'US:NY-3char': [700, 510, 104, 86]
-            'US:NY-4char': [576, 510, 116, 88]
-            'US:NY-5char': [448, 510, 120, 86]
-            'US:PA-1char': [480, 602, 72, 88]
-            'US:PA-2char': [384, 602, 88, 88]
-            'US:PA-3char': [264, 602, 112, 88]
-            'US:PA-4char': [136, 602, 120, 88]
-            'US:PA-5char': [0, 602, 128, 88]
-            'US:US-1char': [480, 790, 88, 94]
-            'US:US-2char': [576, 790, 104, 94]
-            'US:US-3char': [336, 790, 138, 100]
-            'US:US-4char': [172, 790, 158, 100]
-            'US:US-5char': [0, 792, 164, 98]
             airport: [870, 0, 38, 38]
-            aerodrome: [870, 0, 38, 38]
-            aquarium: [870, 204, 38, 38]
-            atm: [46, 204, 38, 38]
-            bakery: [686, 204, 38, 38]
-            bank: [92, 204, 38, 38]
-            category-predicate-money: [92, 204, 38, 38]
-            bar: [368, 204, 38, 38]
-            pub: [368, 204, 38, 38]
-            category-predicate-drink: [368, 204, 38, 38]
-            baseball: [506, 84, 38, 38]
-            basketball: [460, 84, 38, 38]
+            aquarium: [732, 168, 38, 38]
+            art-gallery: [640, 168, 38, 38]
+            athletics-sports: [184, 168, 38, 38]
+            atm: [918, 126, 38, 38]
+            automotive-shop: [0, 168, 38, 38]
+            bakery: [548, 168, 38, 38]
+            bank: [964, 126, 38, 38]
+            bar: [230, 168, 38, 38]
+            baseball-field: [506, 84, 38, 38]
+            basketball-court: [460, 84, 38, 38]
             beach: [644, 84, 38, 38]
+            beer-garden: [322, 210, 38, 38]
             bench: [548, 0, 38, 38]
-            bicycle: [0, 204, 38, 38]
-            bicycle_rental: [0, 204, 38, 38]
-            bicycle_rental_station: [0, 204, 38, 38]
-            bicycle_parking: [772, 126, 38, 38]
-            biergarten: [458, 246, 38, 38]
-            brewery: [458, 246, 38, 38]
-            books: [954, 126, 38, 38]
+            bicycle-parking: [644, 126, 38, 38]
+            bike-shop: [872, 126, 38, 38]
+            boat-ferry: [824, 0, 38, 38]
+            boat-ramp: [138, 84, 40, 38]
+            bookstore: [826, 126, 38, 38]
             bridge: [920, 84, 38, 38]
-            buddhist: [782, 84, 38, 38]
-            building: [552, 204, 38, 38]
-            hangar: [552, 204, 38, 38]
-            nursing_home: [552, 204, 38, 38]
-            manor: [552, 204, 38, 38]
-            apartments: [552, 204, 38, 38]
-            care_home: [552, 204, 38, 38]
-            bus_station: [778, 0, 38, 38]
-            bus_stop: [778, 0, 38, 38]
+            buddhism: [782, 84, 38, 38]
+            building: [414, 168, 34, 34]
+            burger: [184, 210, 38, 38]
+            taqueria: [138, 210, 38, 38]
+            bus-station: [778, 0, 38, 38]
             butcher: [920, 42, 38, 38]
-            cafe: [640, 204, 38, 38]
-            camp_site: [828, 84, 38, 38]
-            summer_camp: [828, 84, 38, 38]
-            caravan_site: [828, 84, 38, 38]
-            capital-l: [726, 246, 32, 32]
-            capital-m: [694, 246, 24, 24]
-            capital-s: [666, 246, 20, 20]
-            capital-xl: [814, 246, 40, 40]
-            capital-xs: [642, 246, 16, 16]
-            car: [908, 126, 38, 38]
-            category-namespace-mobility: [908, 126, 38, 38]
-            category-predicate-mobility: [908, 126, 38, 38]
-            car_repair: [138, 204, 38, 38]
-            car_sharing: [594, 0, 38, 38]
+            campground: [828, 84, 38, 38]
+            candy-store: [0, 210, 38, 38]
+            capital-l: [560, 210, 16, 16]
+            capital-m: [540, 210, 12, 12]
+            capital-s: [520, 210, 10, 10]
+            capital-xl: [584, 210, 20, 20]
+            capital-xs: [506, 210, 8, 8]
+            car-dealership: [780, 126, 38, 38]
             castle: [414, 42, 38, 38]
-            fort: [414, 42, 38, 38]
             cemetery: [736, 84, 38, 38]
-            grave_yard: [736, 84, 38, 38]
-            christian: [230, 126, 38, 38]
-            cinema: [916, 204, 38, 38]
-            clothes: [962, 204, 38, 38]
-            fashion: [962, 204, 38, 38]
-            college: [0, 246, 38, 38]
-            university: [0, 246, 38, 38]
-            confectionery: [136, 246, 38, 38]
-            convenience: [46, 84, 38, 38]
-            county_shield-1char: [640, 602, 72, 72]
-            county_shield-2char: [256, 694, 88, 72]
-            county_shield-3char: [144, 694, 104, 72]
-            county_shield-4char: [0, 694, 136, 72]
-            county_shield-5char: [720, 602, 160, 72]
+            church: [230, 126, 38, 38]
+            clothing-store: [824, 168, 38, 38]
+            coffee-shop: [502, 168, 38, 38]
+            college-university: [870, 168, 38, 38]
+            convenience-store: [46, 84, 38, 38]
             courthouse: [364, 0, 38, 38]
-            department_store: [862, 126, 38, 38]
-            drinking_water: [412, 246, 38, 38]
-            dry_cleaning: [0, 84, 38, 38]
-            electronics: [726, 126, 38, 38]
-            computer: [726, 126, 38, 38]
-            estate_agent: [138, 42, 38, 38]
-            factory: [506, 204, 38, 38]
-            industrial: [506, 204, 38, 38]
-            chimney: [506, 204, 38, 38]
-            substation: [506, 204, 38, 38]
-            wastewater_plant: [506, 204, 38, 38]
-            works: [506, 204, 38, 38]
-            water_works: [506, 204, 38, 38]
-            plant: [506, 204, 38, 38]
-            generator: [506, 204, 38, 38]
-            category-predicate-industry: [506, 204, 38, 38]
-            fast_food: [320, 246, 38, 38]
-            ferry: [824, 0, 38, 38]
-            ferry_terminal: [824, 0, 38, 38]
-            fire_station: [318, 0, 38, 38]
+            department-store: [734, 126, 38, 38]
+            drinking-water: [276, 210, 38, 38]
+            dry-cleaning: [0, 84, 38, 38]
+            electronics-store: [598, 126, 38, 38]
+            factory: [368, 168, 38, 38]
+            fire-station: [318, 0, 38, 38]
             fitness: [874, 42, 38, 38]
-            fitness_station: [874, 42, 38, 38]
-            florist: [184, 126, 38, 38]
-            forest: [182, 246, 38, 38]
-            natural_forest: [182, 246, 38, 38]
-            nature_reserve: [182, 246, 38, 38]
-            conservation: [182, 246, 38, 38]
-            protected_area: [182, 246, 38, 38]
-            grass: [182, 246, 38, 38]
-            fountain: [404, 126, 38, 38]
-            fuel: [90, 246, 38, 38]
-            gallery: [778, 204, 38, 38]
+            flower-shop: [184, 126, 38, 38]
+            forest: [46, 210, 38, 38]
+            fountain: [322, 126, 38, 38]
             garden: [690, 84, 38, 38]
-            generic: [596, 246, 38, 38]
-            category-namespace-other: [596, 246, 38, 38]
-            category-predicate-addressing: [596, 246, 38, 38]
-            generic_shield-1char: [928, 290, 72, 72]
-            generic_shield-2char: [488, 422, 98, 72]
-            generic_shield-3char: [348, 422, 132, 72]
-            generic_shield-4char: [188, 422, 152, 72]
-            generic_shield-5char: [0, 422, 180, 72]
-            gift: [138, 126, 38, 38]
-            golf_course: [414, 84, 38, 38]
-            government: [276, 204, 38, 38]
-            townhall: [276, 204, 38, 38]
-            public: [276, 204, 38, 38]
-            embassy: [276, 204, 38, 38]
-            category-predicate-civic: [276, 204, 38, 38]
-            hairdresser: [46, 42, 38, 38]
-            hardware: [828, 42, 38, 38]
-            doityourself: [828, 42, 38, 38]
-            painter: [828, 42, 38, 38]
-            historical: [92, 126, 38, 38]
-            hospital: [184, 0, 38, 38]
-            category-namespace-health: [184, 0, 38, 38]
-            category-predicate-health: [184, 0, 38, 38]
+            gas-station: [960, 168, 38, 38]
+            generic: [460, 210, 38, 38]
+            gift-shop: [138, 126, 38, 38]
+            golf-course: [414, 84, 38, 38]
+            government-building: [138, 168, 38, 38]
+            grocery-store: [552, 126, 38, 38]
+            harbor-marina: [92, 168, 40, 38]
+            hardware-store: [828, 42, 38, 38]
+            historic-site: [92, 126, 38, 38]
+            hospital: [184, 0, 34, 34]
             hotel: [732, 0, 38, 38]
-            motel: [732, 0, 38, 38]
-            hostel: [732, 0, 38, 38]
-            category-predicate-sleep: [732, 0, 38, 38]
-            ice_cream: [504, 246, 38, 38]
-            information: [550, 246, 38, 38]
-            jewelry: [736, 42, 38, 38]
-            jewish: [46, 0, 38, 38]
+            ice-cream-shop: [368, 210, 38, 38]
+            information: [414, 210, 38, 38]
+            jewelry-store: [736, 42, 38, 38]
             landmark: [272, 0, 38, 38]
-            memorial: [272, 0, 38, 38]
-            monument: [272, 0, 38, 38]
-            tower: [272, 0, 38, 38]
-            beacon: [272, 0, 38, 38]
             laundry: [690, 42, 38, 38]
             library: [0, 0, 38, 38]
-            light_rail: [686, 0, 38, 38]
-            tram_stop: [686, 0, 38, 38]
+            light-rail: [686, 0, 38, 38]
             lighthouse: [276, 84, 38, 38]
-            liquor: [634, 126, 38, 38]
-            alcohol: [634, 126, 38, 38]
+            liquor-store: [506, 126, 38, 38]
+            locate-off: [492, 342, 72, 72]
+            locate-on: [412, 342, 72, 72]
             mall: [644, 42, 38, 38]
-            marina: [230, 204, 38, 38]
-            dock: [230, 204, 38, 38]
-            mineshaft: [782, 42, 38, 38]
-            quarry: [782, 42, 38, 38]
-            adit: [782, 42, 38, 38]
-            mobile_phone: [506, 42, 38, 38]
+            market: [598, 42, 38, 38]
+            mine: [782, 42, 40, 38]
+            mobile-phone-shop: [506, 42, 38, 38]
+            mosque: [92, 0, 38, 38]
+            mountain: [230, 84, 38, 38]
+            movie-theatre: [778, 168, 38, 38]
             museum: [46, 126, 38, 38]
-            observatory: [46, 126, 38, 38]
-            music: [368, 42, 38, 38]
-            muslim: [92, 0, 38, 38]
-            newspaper: [322, 42, 38, 38]
-            kiosk: [322, 42, 38, 38]
+            music-store: [368, 42, 38, 38]
+            newsstand: [322, 42, 38, 38]
             office: [598, 84, 38, 38]
-            insurance: [598, 84, 38, 38]
-            company: [598, 84, 38, 38]
-            category-predicate-service: [598, 84, 38, 38]
-            optician: [276, 42, 38, 38]
-            park: [358, 126, 38, 38]
-            national_park: [358, 126, 38, 38]
-            battlefield: [358, 126, 38, 38]
-            protected_area: [358, 126, 38, 38]
-            category-predicate-nature: [358, 126, 38, 38]
-            park-l: [276, 126, 74, 74]
-            parking: [818, 126, 38, 38]
-            peak: [230, 84, 38, 38]
-            pet: [230, 42, 38, 38]
+            optical-shop: [276, 42, 38, 38]
+            park: [276, 126, 38, 38]
+            parking: [690, 126, 38, 38]
+            performing-arts: [594, 168, 38, 38]
+            pet-store: [230, 42, 38, 38]
             pharmacy: [966, 42, 38, 38]
-            photographic_laboratory: [184, 42, 38, 38]
-            photographer: [184, 42, 38, 38]
+            photography-lab: [184, 42, 38, 38]
             pier: [640, 0, 38, 38]
-            place_of_worship: [414, 204, 38, 38]
-            chapel: [414, 204, 38, 38]
-            wayside_shrine: [414, 204, 38, 38]
-            category-predicate-religion: [414, 204, 38, 38]
             playground: [460, 42, 38, 38]
             police: [226, 0, 38, 38]
-            post_office: [460, 204, 38, 38]
-            recycling: [92, 42, 38, 38]
-            restaurant: [228, 246, 38, 38]
-            category-namespace-eat_and_drink: [228, 246, 38, 38]
-            category-predicate-eat: [228, 246, 38, 38]
-            retail: [598, 42, 38, 38]
-            store: [598, 42, 38, 38]
-            category-namespace-shop_and_service: [598, 42, 38, 38]
-            category-predicate-shop: [598, 42, 38, 38]
+            pool: [184, 84, 38, 38]
+            post-office: [322, 168, 38, 38]
+            real-estate: [138, 42, 38, 38]
+            recycling-facility: [92, 42, 38, 38]
+            rental-car: [594, 0, 38, 38]
+            restaurant: [92, 210, 38, 38]
             ruin: [502, 0, 38, 38]
-            ruins: [502, 0, 38, 38]
-            archaeological_site: [502, 0, 38, 38]
+            salon-barber: [46, 42, 38, 38]
             school: [552, 84, 38, 38]
-            kindergarten: [552, 84, 38, 38]
-            category-namespace-education_and_religion: [552, 84, 38, 38]
-            category-predicate-education: [552, 84, 38, 38]
-            sdk_shield-1char: [592, 422, 84, 84]
-            sdk_shield-2char: [328, 510, 112, 84]
-            sdk_shield-3char: [176, 510, 144, 84]
-            sdk_shield-4char: [0, 510, 168, 84]
-            sdk_shield-5char: [684, 422, 192, 84]
-            shoemaker: [552, 42, 38, 38]
-            ski: [450, 126, 38, 38]
-            winter_sports: [450, 126, 38, 38]
-            slipway: [138, 84, 38, 38]
-            soccer: [368, 84, 38, 38]
-            sports: [0, 42, 38, 38]
-            sports_centre: [322, 204, 38, 38]
-            pitch: [322, 204, 38, 38]
-            recreation_ground: [322, 204, 38, 38]
+            shoe-store: [552, 42, 38, 38]
+            ski-area: [368, 126, 38, 38]
+            soccer-field: [368, 84, 38, 38]
+            spiritual-center: [276, 168, 38, 38]
+            sporting-goods-shop: [0, 42, 38, 38]
             spring: [322, 84, 38, 38]
-            hot_spring: [322, 84, 38, 38]
-            stadium: [542, 126, 38, 38]
-            subway_entrance: [456, 0, 38, 38]
-            supermarket: [680, 126, 38, 38]
-            greengrocer: [680, 126, 38, 38]
-            swimming_pool: [588, 126, 38, 38]
-            tailor: [962, 0, 38, 38]
-            taqueria: [274, 246, 38, 38]
-            tennis: [496, 126, 38, 38]
-            theatre: [732, 204, 38, 38]
-            category-predicate-fun: [732, 204, 38, 38]
-            theme_park: [0, 126, 38, 38]
-            amusement_ride: [0, 126, 38, 38]
+            stadium: [460, 126, 38, 38]
+            subway-entrance: [456, 0, 38, 38]
+            synagogue: [46, 0, 38, 38]
+            tailor-shop: [962, 0, 38, 38]
+            tennis: [414, 126, 38, 38]
+            theme-park: [0, 126, 38, 38]
             toilets: [874, 84, 38, 38]
-            townspot-l: [132, 288, 32, 32]
-            townspot-l-rev: [942, 246, 32, 32]
-            townspot-m: [100, 288, 24, 24]
-            townspot-m-rev: [910, 246, 24, 24]
-            townspot-s: [72, 288, 20, 20]
-            townspot-s-rev: [882, 246, 20, 20]
-            townspot-xl: [172, 288, 40, 40]
-            townspot-xl-rev: [0, 290, 40, 40]
-            townspot-xs: [48, 288, 16, 16]
-            townspot-xs-rev: [862, 246, 12, 12]
-            toys: [916, 0, 38, 38]
-            traffic_signals: [46, 246, 38, 38]
-            train_station: [410, 0, 38, 38]
-            station: [410, 0, 38, 38]
-            train: [410, 0, 38, 38]
-            category-predicate-transport: [410, 0, 38, 38]
-            ux-current-location: [514, 290, 88, 88]
-            ux-locate-off: [848, 290, 72, 72]
-            ux-locate-on: [768, 290, 72, 72]
-            ux-route-arrow: [220, 290, 128, 128]
-            ux-route-start: [434, 290, 72, 92]
-            ux-route-stop: [356, 290, 72, 92]
-            ux-search-active: [608, 290, 72, 108]
-            ux-search-inactive: [688, 290, 72, 108]
-            ux-transit-stop: [766, 248, 42, 36]
-            veterinary: [138, 0, 38, 38]
-            viewpoint: [824, 204, 38, 38]
-            category-namespace-do_and_see: [824, 204, 38, 38]
-            category-predicate-attraction: [824, 204, 38, 38]
-            vineyard: [184, 204, 38, 38]
+            townspot-l: [770, 210, 16, 16]
+            townspot-l-rev: [664, 210, 16, 16]
+            townspot-m: [750, 210, 12, 12]
+            townspot-m-rev: [644, 210, 12, 12]
+            townspot-s: [732, 210, 10, 10]
+            townspot-s-rev: [626, 210, 10, 10]
+            townspot-xl: [794, 210, 20, 20]
+            townspot-xl-rev: [688, 210, 20, 20]
+            townspot-xs: [716, 210, 8, 8]
+            townspot-xs-rev: [612, 210, 6, 6]
+            toy-game-store: [916, 0, 38, 38]
+            traffic-signal: [916, 168, 36, 34]
+            train-station: [410, 0, 38, 38]
+            veterinarian: [138, 0, 38, 38]
+            view-point: [686, 168, 40, 38]
+            vineyard: [46, 168, 40, 38]
             volcano: [92, 84, 38, 38]
-            water_park: [184, 84, 38, 38]
-            wine: [366, 246, 38, 38]
-            winery: [594, 204, 38, 38]
+            wine-bar: [230, 210, 38, 38]
+            winery: [456, 168, 38, 38]
             zoo: [966, 84, 38, 38]
+            #
+            # UX/UI icons for map interactivity & app chrome
+            #
+            ux-current-location: [158, 342, 88, 88]
+            ux-route-arrow: [822, 210, 128, 128]
+            ux-route-start: [78, 342, 72, 92]
+            ux-route-stop: [0, 342, 72, 92]
+            ux-search-active: [252, 342, 72, 108]
+            ux-search-inactive: [332, 342, 72, 108]
+            # ux-transit-stop is currently reusing capital-xl artwork, please customize
+            ux-transit-stop: [584, 210, 20, 20]
 
     building-grid:
         url: images/building-grid.gif
-        #url: https://raw.githubusercontent.com/tangrams/bubble-wrap/gh-pages/images/building-grid.gif
         filtering: mipmap
 
-fonts:
-    Open Sans:
-        - weight: 300 # Light
-          url: fonts/OpenSans-Light.woff
-        - weight: normal # Regular
-          url: fonts/OpenSans-Regular.woff
-        - weight: normal # Regular
-          style: italic
-          url: fonts/OpenSans-Italic.woff
-        - weight: 600 # Semi Bold
-          url: fonts/OpenSans-Semibold.woff
-        - weight: 600 # Semi Bold
-          style: italic
-          url: fonts/OpenSans-SemiboldItalic.woff
-        - weight: bold
-          url: fonts/OpenSans-Bold.woff
-    Montserrat:
-        - weight: normal
-          #url: https://fonts.gstatic.com/s/montserrat/v7/zhcz-_WihjSQC0oHJ9TCYL3hpw3pgy2gAi-Ip7WPMi0.woff
-          url: fonts/Montserrat-Regular.woff
-    Varela:
-        - weight: normal
-          #url: https://fonts.gstatic.com/s/varela/v7/maB5vWJo0EAVzvHPjBkLM-vvDin1pK8aKteLpeZ5c0A.woff
-          url: fonts/Varela-Regular.woff
-    Quicksand:
-        - weight: normal
-          #url: https://fonts.gstatic.com/s/quicksand/v6/sKd0EMYPAh5PYCRKSryvW7O3LdcAZYWl9Si6vvxL-qU.woff
-          url: fonts/Quicksand-Regular.woff
-
 sources:
     mapzen:
         # EraserMaps the app only supports MVT format tiles
         type:  MVT #TopoJSON
-        url:  https://tile.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.mvt
         #url:  http://tile.dev.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.mvt
+        url:  https://tile.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.mvt
+        #enforce_winding: true  #because Tangram v0.4 and tiles v0.5-pre don't play nice
         #url:  //localhost:8080/vector/all/{z}/{x}/{y}.mvt
         # road labels in Tangram JS are broken when overzooming, set max_zoom: 18 to preview fix
         url_params:
-            api_key: global.sdk_mapzen_api_key
+            api_key:
         max_zoom: 16
 
 #    # Only enable this for local debug, should not be enabled for prod (app inserts these at runtime)
@@ -767,9 +558,9 @@ sources:
 #    mz_route_line:
 #        type: GeoJSON
 #        # sf to ny
-#        url: https://gist.githubusercontent.com/anonymous/30c6c1a75c168d91d90c/raw/92bfe55e622766d250b1f2f5d17bdc7c26acb956/map.geojson
+#        url: https://gist.githubusercontent.com/anonymous/30c6c1a75c168d91d90c/raw/92bfe55e622766d250b1f2f5d17bdc7c26acb956/map.geojson
 #        # local sf trip
-#        url: https://gist.githubusercontent.com/anonymous/9a610ebda6fe4be7bccc/raw/8d217e43f2412d48d01534ba115f1e42dac72e68/map.geojson
+#        url: https://gist.githubusercontent.com/anonymous/9a610ebda6fe4be7bccc/raw/8d217e43f2412d48d01534ba115f1e42dac72e68/map.geojson
 #    # Dashed route line
 #    mz_dash_line:
 #        type: GeoJSON
@@ -802,10 +593,6 @@ sources:
 #    mz_default_point:
 #        type: GeoJSON
 #        url: https://gist.githubusercontent.com/anonymous/16324c771edfce45be0721390389b878/raw/7dbaebf17da7da8562e6c6f8768bc8cff83efa88/map.geojson
-#    # Default shield styling (SDK)
-#    mz_default_shield:
-#        type: GeoJSON
-#        url: https://gist.githubusercontent.com/nvkelso/3c08dba1eced4d01df98c1a9a7801162/raw/d83a5a396fc7b22309b8ca89336ad2dcfff6c452/map.geojson
 #    # Default line styling (SDK)
 #    mz_default_line:
 #        type: GeoJSON
@@ -824,14 +611,23 @@ styles:
         base: lines
         dash: [1.25, 1.25]
         dash_background_color: [0.808,0.860,0.851]
-    dashed_big:
-        base: lines
-        dash: [2.0, 1.0]
-        dash_background_color: [0.808,0.860,0.851]
-    dashed_steps:
+    dashedline:
         base: lines
-        dash: [0.5, 0.5]
-        dash_background_color: [0.867, 0.867, 0.867]
+        texcoords: true
+        shaders:
+            defines:
+                background: vec3(0.867, 0.867, 0.867)
+            blocks:
+                color: |
+                    // blend line 50/50 between two colors
+                    float t = fract(v_texcoord.y);
+                    float e = 0.1; // edge feather
+                    vec3 v = vec3(
+                        smoothstep(.0, e, t) *
+                        (1. - smoothstep(.5, .5 + e, t))
+                    );
+                    color.rgb = mix(color.rgb, background, v);
+
     tools-tilecoords:
         shaders:
             blocks:
@@ -845,6 +641,7 @@ styles:
                     #endif
                 position: |
                     v_pos = modelPosition().xy;
+
     tools-aastep:
         shaders:
             extensions: OES_standard_derivatives
@@ -862,6 +659,7 @@ styles:
                             return step(threshold, value);
                         #endif
                     }
+
     tools-grid:
         mix: tools-tilecoords
         shaders:
@@ -877,21 +675,60 @@ styles:
                         float pct = 0.0;
                         float press = 0.4 + (1.0 - fract(u_map_position.z)) * 0.1;
                         if (grid(st, 0.01, press)) { pct += 0.5; }
-                        if (grid(st, 0.1, press)) { pct += 0.15; }
+                        if (grid(st, 0.1, press)) { pct += 0.1; }
                         return pct;
                     }
                     float TileGrid() {
                         return mix(TileGrid(1.), TileGrid(2.), fract(u_map_position.z));
                     }
                     #endif
+
+    tools-grain:
+        shaders:
+            blocks:
+                global: |
+                    // Grain
+                    //=============================
+                    float random(vec2 p) {
+                        return fract(1e4 * sin(17.0 * p.x + p.y * 0.1) * (0.1 + abs(sin(p.y * 13.0 + p.x))));
+                    }
+                    float noise(vec2 x) {
+                        vec2 i = floor(x);
+                        vec2 f = fract(x);
+                        float a = random(i);
+                        float b = random(i + vec2(1.0, 0.0));
+                        float c = random(i + vec2(0.0, 1.0));
+                        float d = random(i + vec2(1.0, 1.0));
+                        vec2 u = f * f * (3.0 - 2.0 * f);
+                        return mix(a, b, u.x) + (c - a) * u.y * (1.0 - u.x) + (d - b) * u.x * u.y;
+                    }
+                    float fbm(in vec2 p) {
+                        float s = 0.0;
+                        float m = 0.0;
+                        float a = 0.5;
+                        for(int i = 0; i < 2; i++ ) {
+                            s += a * noise(p);
+                            m += a;
+                            a *= 0.5;
+                            p *= 2.0;
+                        }
+                        return s/m;
+                    }
+                    float grain(vec2 pos) {
+                        vec2 st = pos / u_resolution.xy - vec2(.5);
+                        return dot(st, st) + (fbm(pos * 0.6) * 0.1);
+                    }
+
     grid:
         base: polygons
-        mix: [tools-grid]
+        mix: [tools-grain, tools-grid]
         shaders:
             blocks:
                 filter: |
                     color.rgb = vec3(0.899, 0.95, 1.0);
-                    color.rgb = mix(color.rgb, vec3(0.654,0.856,0.896), TileGrid());
+                    color.rgb -= grain(gl_FragCoord.xy) * 0.1;
+                    color.rgb = mix(color.rgb, vec3(0.639, 0.886, 0.906), TileGrid());
+
     water_border:
         base: lines
         texcoords: true
@@ -912,6 +749,7 @@ styles:
                     vec2 st = v_texcoord.xy;
                     float pattern = aastep(.5, pulse(st.x, .75, .15) + pulse(st.x, .4, .10) + pulse(st.x, .1, .1));
                     color.rgb = mix(color.rgb, vec3(0.675,0.855,0.886), pattern);
+
     shapes-circle:
         shaders:
             blocks:
@@ -934,6 +772,7 @@ styles:
                         st.x += step(1., mod(st.y, 2.0)) * 0.5;
                         return fract(st);
                     }
+
     pattern-dots:
         mix: [tools-tilecoords, tiling-brick, shapes-circle, tools-aastep]
         shaders:
@@ -959,7 +798,8 @@ styles:
                             return aastep(size, d);
                         }
                     #endif
-    dots:
+
+    dots2:
         base: polygons
         mix: pattern-dots
         shaders:
@@ -1035,6 +875,34 @@ styles:
                                         texture2D(u_tex_grid, v_texcoord).a);
                     }
 
+    # building-grid-univ:
+    #     mix: building-grid
+    #     shaders:
+    #         defines:
+    #             ROOF_COLOR: vec3(0.922,0.894,0.862)
+    #             WALL_COLOR: vec3(0.658,0.617,0.576)
+
+    # building-grid-parks:
+    #     mix: building-grid
+    #     shaders:
+    #         defines:
+    #             ROOF_COLOR: vec3(0.847,0.886,0.882)
+    #             WALL_COLOR: vec3(0.627,0.722,0.718)
+
+    # building-grid-hospital:
+    #     mix: building-grid
+    #     shaders:
+    #         defines:
+    #             ROOF_COLOR: vec3(0.941,0.894,0.898)
+    #             WALL_COLOR: vec3(0.692,0.575,0.586)
+
+    # building-grid-retail:
+    #     mix: building-grid
+    #     shaders:
+    #         defines:
+    #             ROOF_COLOR: vec3(0.945,0.898,0.878)
+    #             WALL_COLOR: vec3(0.725,0.694,0.678)
+
     building-lines:
         base: lines
         mix: scale-buildings
@@ -1071,24 +939,19 @@ styles:
     ux-location-gem-overlay:
         base: points
         texture: pois
+        interactive: true
         blend: overlay
         blend_order: 2
     ux-icons-overlay:
         base: points
         texture: pois
-        interactive: global.sdk_interactive
+        interactive: true
         blend: overlay
         blend_order: 3
     sdk-point-overlay:
         base: points
         texture: pois
-        interactive: global.sdk_interactive
-        blend: overlay
-        blend_order: 3
-    sdk-shield-overlay:
-        base: points
-        texture: pois
-        interactive: global.sdk_interactive
+        interactive: true
         blend: overlay
         blend_order: 3
     sdk-line-overlay:
@@ -1134,58 +997,73 @@ layers:
         data: { source: mz_current_location }
         draw:
             ux-location-gem-overlay:
+                interactive: true
                 sprite: ux-current-location
                 size: 36px
                 collide: false
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_route_location:
         data: { source: mz_route_location }
         draw:
             ux-location-gem-overlay:
+                interactive: true
                 sprite: ux-route-arrow
                 size: [60px,60px]
                 collide: false
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_route_start:
         data: { source: mz_route_start }
         draw:
             ux-icons-overlay:
-                interactive: global.sdk_interactive
+                interactive: true
                 priority: 1
                 sprite: ux-route-start
                 size: [36px,46px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_route_destination:
         data: { source: mz_route_destination }
         draw:
             ux-icons-overlay:
-                interactive: global.sdk_interactive
+                interactive: true
                 priority: 1
                 sprite: ux-route-stop
                 size: [36px,46px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_route_transit_stop:
         data: { source: mz_route_transit_stop }
         draw:
             ux-icons-overlay:
+                interactive: true
                 sprite: ux-transit-stop
                 size: [15px,15px]
                 collide: false
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                     [show, hide]:
+                         time: 0s
     mz_search_result:
         data: { source: mz_search_result }
         draw:
             ux-icons-overlay:
-                interactive: global.sdk_interactive
+                interactive: true
                 sprite: ux-search-active
                 size: [36px,54px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
         inactive:
             filter: { state: inactive }
             draw:
@@ -1195,130 +1073,28 @@ layers:
         data: { source: mz_dropped_pin }
         draw:
             ux-icons-overlay:
+                interactive: true
                 sprite: ux-search-active
                 size: [36px,54px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
 
     # Used by the SDK to place point, line, and polygon overlays on the map
     mz_default_point:
         data: { source: mz_default_point }
         draw:
             sdk-point-overlay:
-                interactive: global.sdk_interactive
+                interactive: true
                 sprite: ux-search-active
                 size: [36px,54px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
-    mz_default_shield:
-        data: { source: mz_default_shield }
-        draw:
-            sdk-shield-overlay:
-                interactive: global.sdk_interactive
-                sprite: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return ('sdk_shield-' + feature.shield_text.length + 'char');
-                        } else {
-                            return ('sdk_shield-' + feature.name.length + 'char');
-                        }
-                    }
-                sprite_default: sdk_shield-1char
-                color: global.sdk_shield_color
-                collide: false
-                transition: { show: { time: 0s }, hide: { time: 0s } }
-                text:
-                    # offset: [0px, -1px]
-                    text_source: |
-                        function() {
-                            if( feature.shield_text ) {
-                                return feature.shield_text;
-                            } else {
-                                return feature.name;
-                            }
-                        }
-                    anchor: center
-                    font:
-                        family: Montserrat
-                        fill: global.sdk_shield_text_color
-                        style: bold
-                        size: [[7,7px],[12,8px],[16,11px]]
-
-        width_1char:
-            filter: |
-                function() {
-                    if( feature.shield_text ) {
-                        return (feature.shield_text.length === 1);
-                    } else {
-                        return (feature.name.length === 1);
-                    }
-                }
-            draw:
-                sdk-shield-overlay:
-                    size: [[6,[16px,16px]],[13,[18px,18px]],[16,[21px,21px]]]
-        width_2char:
-            filter: |
-                function() {
-                    if( feature.shield_text ) {
-                        return (feature.shield_text.length === 2);
-                    } else {
-                        return (feature.name.length === 2);
-                    }
-                }
-            draw:
-                sdk-shield-overlay:
-                    size: [[6,[21px,16px]],[13,[24px,18px]],[16,[28px,21px]]]
-        width_3char:
-            filter: |
-                function() {
-                    if( feature.shield_text ) {
-                        return (feature.shield_text.length === 3);
-                    } else {
-                        return (feature.name.length === 3);
-                    }
-                }
-            draw:
-                sdk-shield-overlay:
-                    size: [[6,[27px,16px]],[13,[31px,18px]],[16,[36px,21px]]]
-        width_4char:
-            filter: |
-                function() {
-                    if( feature.shield_text ) {
-                        return (feature.shield_text.length === 4);
-                    } else {
-                        return (feature.name.length === 4);
-                    }
-                }
-            draw:
-                sdk-shield-overlay:
-                    size: [[6,[32px,16px]],[13,[36px,18px]],[16,[41px,21px]]]
-        width_5char:
-            filter: |
-                function() {
-                    if( feature.shield_text ) {
-                        return (feature.shield_text.length === 5);
-                    } else {
-                        return (feature.name.length === 5);
-                    }
-                }
-            draw:
-                sdk-shield-overlay:
-                    size: [[6,[37px,16px]],[13,[41px,18px]],[16,[48px,21px]]]
-        # this is kinda a hack
-        width_longggggg:
-            filter: |
-                function() {
-                    if( feature.shield_text ) {
-                        return (feature.shield_text.length > 5);
-                    } else {
-                        return (feature.name.length > 5);
-                    }
-                }
-            draw:
-                sdk-shield-overlay:
-                    visible: false
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_default_line:
         data: { source: mz_default_line }
         draw:
@@ -1376,16 +1152,16 @@ layers:
                 grid:
                     color: global.water1
         other-water-areas:
-            filter: { not: { kind: [ocean, lake, water, reservoir, swimming_pool, playa] }, $zoom: { min: 11 }, area: { min: 100 } }
+            filter: { not: { kind: [ocean, lake, water, reservoir, playa, swimming_pool] }, $zoom: { min: 11 }, area: { min: 100 } }
             draw:
                 grid:
                     color: global.water1
         playas:
-            filter: { kind: playa }
+            filter: { kind: playa, $zoom: {min: 6} }
             draw:
                 polygons:
-                    order: function() { return feature.sort_rank + 1; }
-                    color: global.water2 #[0.870,0.870,0.870]
+                    order: global.feature_order
+                    color: [0.870,0.870,0.870]
         water-boundary-ocean-early:
             filter: { boundary: true, kind: ocean, $zoom: {min: 1, max: 17} }
             draw:
@@ -1443,167 +1219,41 @@ layers:
                         color: [[11,[0.671,0.788,0.812]],[13,[0.710,0.800,0.824]],[14,[0.635,0.812,0.843]]]
                         width: [[9,0px],[11,0px],[12,0px],[13,0.5px],[14,0.75px],[15,0.75px],[16,0.75px],[17,1px]]
 
-        water-labels:
-            filter:
-                all:
-                    - name: true
-                    - function() { return global.text_visible_water_labels; }
-            water-line-labels:
-                filter:
-                    $geometry: line
-                    kind: [river,canal,stream,dam,ditch,drain]
-                    $zoom: { min: 14 }
-                draw:
-                    text-blend-order:
-                        text_source: global.ux_language_text_source
-                        font:
-                            fill: [0.314,0.591,0.640]
-                            family: global.text_font_family
-                            style: italic
-                            weight: normal
-                            size: 12px
-                water-line-labels-z14:
-                    filter: { $zoom: [14] }
-                    draw:
-                        text-blend-order: { font: { size: 10px } }
-                water-line-labels-z17:
-                    filter: { $zoom: [17] }
-                    draw:
-                        text-blend-order: { font: { size: 14px } }
-                not-river-not-stream:
-                    filter: { kind: [canal,dam,ditch,drain], $zoom: { max: 16 } }
-                    draw:
-                        text-blend-order:
-                            visible: false
-                stream:
-                    filter: { kind: [stream], $zoom: { max: 17 } }
-                    draw:
-                        text-blend-order:
-                            visible: false
-
-            water-area-labels:
-                filter:
-                    all:
-                        - $geometry: point
-                        - not: { kind: [riverbank, dock, playa] }
-                        - area: true
-                    any:
-                        # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: { min: 5 },  area: { min: 10000000000 } }
-                        - { $zoom: { min: 6 },  area: { min: 5000000000 } }
-                        - { $zoom: { min: 7 },  area: { min: 400000000 } }
-                        - { $zoom: { min: 8 },  area: { min: 200000000 } }
-                        - { $zoom: { min: 9 },  area: { min: 100000000 } }
-                        - { $zoom: { min: 10 }, area: { min: 100000000 } }
-                        - { $zoom: { min: 11 }, area: { min: 10000000 } }
-                        - { $zoom: { min: 12 }, area: { min: 2000000 } }
-                        - { $zoom: { min: 13 }, area: { min: 1000000 } }
-                        - { $zoom: { min: 14 }, area: { min: 500000 } }
-                        - { $zoom: { min: 15 }, area: { min: 100000 } }
-                        - { $zoom: { min: 15 }, area: { min: 50000 } }
-                        - { $zoom: { min: 16 }, area: { min: 20000 } }
-                        - { $zoom: { min: 17 } }
-                default-label-text:
-                    draw:
-                        text-blend-order:
-                            text_source: global.ux_language_text_source
-                            font:
-                                fill: [0.314,0.591,0.640] #global.text_fill_water
-                                family: global.text_font_family
-                                style: italic
-                                weight: normal
-                                size: 12px
-                lakes-labels:
-                    filter:
-                        $zoom: { min: 4 }
-                    draw:
-                        text-blend-order:
-                            font:
-                                size: [[5,9px],[8,12px]]
-
-            ocean-sea-labels:
-                filter:
-                    kind: [sea, ocean]
-                draw:
-                    text-blend-order:
-                        text_source: global.ux_language_text_source
-                        font:
-                            fill: [0.314,0.591,0.640] #global.text_fill_water
-                            family: global.text_font_family
-                            weight: normal
-                            size: 8px
-                            transform: uppercase
-                ocean-spacer:
-                    filter: { kind: ocean }
-                    ocean-spacer-z1-z4:
-                        filter: { $zoom: { min: 1, max: 4 } }
-                        draw:
-                            text-blend-order:
-                                text_source: global.ux_language_text_source_sea
-                                text_wrap: false
-                    ocean-spacer-z4-up:
-                        filter: { $zoom: { min: 4 } }
-                        draw:
-                            text-blend-order:
-                                text_source: global.ux_language_text_source_ocean
-                                text_wrap: false
-                ocean-labels:
-                    draw:
-                        text-blend-order:
-                            font:
-                                size: [[1,8px],[4,16px]]
-                sea-early:
-                    filter: { $zoom: [3], kind: sea }
-                    draw: { text-blend-order: { visible: false } }
-
-                sea-spacer:
-                    filter: { not: { kind: [ocean] }, $zoom: { min: 4 } }
-                    draw:
-                        text-blend-order:
-                            text_source: global.ux_language_text_source_sea
-                            text_wrap: false
-                sea-labels:
-                    filter: { not: { kind: [ocean] } }
-                    draw:
-                        text-blend-order:
-                            font:
-                                size: [[4,9px],[8,16px]]
-
-            playa-labels:
-                filter:
-                    all:
-                        - $geometry: point
-                        - kind: playa
-                        - area: true
-                    any:
-                        # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: { min: 7 },  area: { min: 1500000000 } }
-                        - { $zoom: { min: 8 },  area: { min: 200000000 } }
-                        - { $zoom: { min: 9 },  area: { min: 100000000 } }
-                        - { $zoom: { min: 10 }, area: { min: 100000000 } }
-                        - { $zoom: { min: 11 }, area: { min: 10000000 } }
-                        - { $zoom: { min: 12 }, area: { min: 2000000 } }
-                        - { $zoom: { min: 13 }, area: { min: 1000000 } }
-                        - { $zoom: { min: 14 }, area: { min: 500000 } }
-                        - { $zoom: { min: 15 }, area: { min: 100000 } }
-                        - { $zoom: { min: 15 }, area: { min: 50000 } }
-                        - { $zoom: { min: 16 }, area: { min: 20000 } }
-                        - { $zoom: { min: 17 } }
-                draw:
-                    text-blend-order:
-                        text_source: global.ux_language_text_source
-                        font:
-                            fill: grey
-                            family: global.text_font_family
-                            style: italic
-                            weight: normal
-                            size: 12px
-                            stroke: { color: global.text_stroke_water, width: 3 }
-                # debug only
-        #        icons:
-        #            size: [[13, 12px], [15, 18px]]
-        #            sprite: global.townspot_sprite
-
+    water-line-labels:
+        data: { source: mapzen, layer: [water] }
+        filter:
+            all:
+                - name: true
+                - $geometry: line
+                - kind: [river,canal,stream,dam,ditch,drain]
+                - $zoom: { min: 14 }
+        draw:
+            text-blend-order:
+                text_source: global.ux_language_text_source
+                font:
+                    fill: [0.314,0.591,0.640]
+                    family: global.text_font_family
+                    style: italic
+                    weight: 400
+                    size: 12px
+        water-line-labels-z14:
+            filter: { $zoom: [14] }
+            draw:
+                text-blend-order: { font: { size: 10px } }
+        water-line-labels-z17:
+            filter: { $zoom: [17] }
+            draw:
+                text-blend-order: { font: { size: 14px } }
+        not-river-not-stream:
+            filter: { kind: [canal,dam,ditch,drain], $zoom: { max: 16 } }
+            draw:
+                text-blend-order:
+                    visible: false
+        stream:
+            filter: { kind: [stream], $zoom: { max: 17 } }
+            draw:
+                text-blend-order:
+                    visible: false
 
     transit-basemap:
         data: { source: mapzen, layer: transit }
@@ -1611,7 +1261,8 @@ layers:
             filter: { not: { kind: [platform] }, $zoom: { min: 14 } }
             draw:
                 lines:
-                    order: function() { return feature.sort_rank || 275; }
+                    interactive: true
+                    order: function() { return feature.sort_key || 275; }
             railway:
                 filter: { kind: [railway,train] }
                 draw:
@@ -1672,20 +1323,12 @@ layers:
                             color: global.grey9_o
                             width: [[16,0px],[17,0.5px],[19,2px]]
 
-#    # useful to example road geometry merging & Tangram labeling w/r/t tile boundaries
-#    z-randomColor:
-#        data: { source: mapzen, layer: roads }
-#        draw:
-#            lines:
-#                order: 1000
-#                # color: '#777'
-#                color: function() { return [Math.random(), Math.random(), Math.random()] }
-#                width: [[13,0.5px],[14,1px],[16,2px]]
-
     roads:
         data: { source: mapzen, layer: roads }
+        filter: { not: { kind: rail } }
         draw:
             lines:
+                interactive: true
                 # let roads sort themselves past zoom 14 (using server value)
                 order: global.feature_order
                 # but give them all the same outline
@@ -1696,12 +1339,11 @@ layers:
                 visible: false    # labels are enabled by each layer below
                 font:
                     family: global.text_font_family
-                    weight: normal
+                    weight: 400
                     fill: global.text_fill
-                    size: 12px
 
         natural_earth_highways:
-            filter: { source: 'naturalearthdata.com', $zoom: { max: 8 } }
+            filter: { source: 'naturalearthdata.com' }
             draw:
                 lines:
                     # Perf impact (too many vertices)
@@ -1710,25 +1352,25 @@ layers:
                     color: global.highway1
                     width: [[5, 1px], [7, 1.4px], [9, 1.5px], [14, 3px], [16, 4px], [17, 10m]]
             major_road:
-                filter: { kind: major_road }
+                filter: { type: ['Secondary Highway','Road'] }
                 draw:
                     lines:
                         color: [0.980,0.601,0.559]
                         width: [[5, 0.45px], [6, 0.75px], [7, 1.0px], [8, 1px]]
             minor_road:
-                filter: { kind: minor_road }
+                filter: { type: 'Unknown' }
                 draw:
                     lines:
                         color: [[12, global.minor_road1], [17, global.minor_road2]]
                         width: [[12, 1.0px], [14, 1.5px], [15, 3px], [16, 5m]]
             ferry:
-                filter: { kind: ferry }
+                filter: { kind: Ferry }
                 draw:
                     lines:
                         color: [0.702,0.843,0.933]
                         width: 1px
         highway:
-            filter: { kind: highway, $zoom: { min: 8 } }
+            filter: { kind: highway }
             draw:
                 lines:
                     color: [[8, global.highway1], [14, global.highway1], [15, [1.0,1.0,1.0]], [17, [1.0,1.0,1.0]]]
@@ -1784,59 +1426,54 @@ layers:
                 draw:
                     text-blend-order:
                         text_source: global.ux_language_text_source_road_ref_and_name
-            # labels-highway-early:
-            #     filter:
-            #         $zoom: [7,8,9]
-            #         shield_text: false
-            #     draw:
-            #         text-blend-order:
-            #             priority: 50
-            #             visible: global.sdk_road_shields
-            #             text_source: ref
-            #             font:
-            #                 fill: [1.0,1.0,1.0]
-            #                 weight: 600
-            #                 size: 9px
-            #                 stroke: { color: [0.976,0.541,0.490], width: 3 }
-            # labels-highway-z10:
-            #     filter:
-            #         $zoom: 10
-            #         shield_text: false
-            #     draw:
-            #         text-blend-order:
-            #             visible: global.sdk_road_shields
-            #             text_source: ref
-            #             font:
-            #                 fill: [1.0,1.0,1.0]
-            #                 weight: 600
-            #                 size: 10px
-            #                 stroke: { color: [0.976,0.541,0.490], width: 3 }
-            # labels-highway-z11:
-            #     filter:
-            #         $zoom: 11
-            #         shield_text: false
-            #     draw:
-            #         text-blend-order:
-            #             visible: global.sdk_road_shields
-            #             text_source: ref
-            #             font:
-            #                 fill: [1.0,1.0,1.0]
-            #                 weight: 600
-            #                 size: 11px
-            #                 stroke: { color: [0.976,0.541,0.490], width: 3 }
-            # labels-highway-z12:
-            #     filter:
-            #         $zoom: 12
-            #         shield_text: false
-            #     draw:
-            #         text-blend-order:
-            #             visible: global.sdk_road_shields
-            #             text_source: ref
-            #             font:
-            #                 fill: [1.0,1.0,1.0]
-            #                 weight: 600
-            #                 size: 12px
-            #                 stroke: { color: [0.976,0.541,0.490], width: 3 }
+            labels-highway-early:
+                filter: { $zoom: [7,8,9] }
+                draw:
+                    text-blend-order:
+                        priority: 50
+                        visible: global.text_visible_shields
+                        text_source: ref
+                        font:
+                            fill: [1.0,1.0,1.0]
+                            weight: 600
+                            size: 9px
+                            stroke: { color: [0.976,0.541,0.490], width: 3 }
+            labels-highway-z10:
+                filter:
+                    $zoom: 10
+                draw:
+                    text-blend-order:
+                        visible: global.text_visible_shields
+                        text_source: ref
+                        font:
+                            fill: [1.0,1.0,1.0]
+                            weight: 600
+                            size: 10px
+                            stroke: { color: [0.976,0.541,0.490], width: 3 }
+            labels-highway-z11:
+                filter:
+                    $zoom: 11
+                draw:
+                    text-blend-order:
+                        visible: global.text_visible_shields
+                        text_source: ref
+                        font:
+                            fill: [1.0,1.0,1.0]
+                            weight: 600
+                            size: 11px
+                            stroke: { color: [0.976,0.541,0.490], width: 3 }
+            labels-highway-z12:
+                filter:
+                    $zoom: 12
+                draw:
+                    text-blend-order:
+                        visible: global.text_visible_shields
+                        text_source: ref
+                        font:
+                            fill: [1.0,1.0,1.0]
+                            weight: 600
+                            size: 12px
+                            stroke: { color: [0.976,0.541,0.490], width: 3 }
             labels-highway-z13:
                 filter:
                     $zoom: 13
@@ -1896,7 +1533,7 @@ layers:
                             stroke: { color: [1.000,1.000,1.000], width: 4 }
 
         major_road:
-            filter: { kind: major_road, $zoom: { min: 8 } }
+            filter: { kind: major_road }
             # default style
             draw:
                 lines:
@@ -1956,25 +1593,22 @@ layers:
                         draw:
                             text-blend-order:
                                 text_source: global.ux_language_text_source_road_ref_and_name
-                                visible: global.text_visible_trunk_primary_route
-                    # labels-trunk_primary-route-z13:
-                    #     filter:
-                    #         $zoom: { max: 14 }
-                    #         shield_text: false
-                    #     draw:
-                    #         text-blend-order:
-                    #             text_source: ref
-                    #             visible: global.text_visible_trunk_primary_route
-                    #             font:
-                    #                 fill: [1.0,1.0,1.0]
-                    #                 weight: 600
-                    #                 size: 11px
-                    #                 stroke: { color: [0.976,0.541,0.490], width: 2 }
+                    labels-trunk_primary-route-z13:
+                        filter: { $zoom: { max: 14 } }
+                        draw:
+                            text-blend-order:
+                                text_source: ref
+                                font:
+                                    fill: [1.0,1.0,1.0]
+                                    weight: 600
+                                    size: 11px
+                                    stroke: { color: [0.976,0.541,0.490], width: 2 }
                     labels-trunk_primary-route-z14:
                         filter: { $zoom: [14] }
                         draw:
                             text-blend-order:
-                                priority: 51
+                                priority: 53
+                                visible: global.text_visible_trunk_primary_e2
                                 #text_source: ref
                                 font:
                                     fill: [0.0,0.0,0.0]
@@ -1984,7 +1618,8 @@ layers:
                         filter: { $zoom: [15] }
                         draw:
                             text-blend-order:
-                                priority: 51
+                                priority: 53
+                                visible: global.text_visible_trunk_primary
                                 #text_source: global.ux_language_text_source_road_ref_and_name
                                 font:
                                     fill: [0.0,0.0,0.0]
@@ -1995,7 +1630,8 @@ layers:
                         filter: { $zoom: { min: 16 } }
                         draw:
                             text-blend-order:
-                                priority: 51
+                                priority: 53
+                                visible: global.text_visible_trunk_primary
                                 #text_source: global.ux_language_text_source_road_ref_and_name
                                 font:
                                     fill: [0.0,0.0,0.0]
@@ -2006,13 +1642,12 @@ layers:
                     draw:
                         text-blend-order:
                             text_source: global.ux_language_text_source_road_ref_and_name_short
-                            visible: global.text_visible_trunk_primary
                 labels-trunk_primary-z11:
                     filter:
                         $zoom: [11]
                     draw:
                         text-blend-order:
-                            priority: 51
+                            priority: 53
                             visible: global.text_visible_trunk_primary_e
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
@@ -2024,7 +1659,7 @@ layers:
                         $zoom: [12]
                     draw:
                         text-blend-order:
-                            priority: 51
+                            priority: 53
                             visible: global.text_visible_trunk_primary_e
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
@@ -2036,7 +1671,8 @@ layers:
                         $zoom: [13]
                     draw:
                         text-blend-order:
-                            priority: 51
+                            priority: 53
+                            visible: global.text_visible_trunk_primary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.25,0.25,0.25]
@@ -2047,7 +1683,8 @@ layers:
                         $zoom: [14]
                     draw:
                         text-blend-order:
-                            priority: 51
+                            priority: 53
+                            visible: global.text_visible_trunk_primary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.10,0.10,0.10]
@@ -2057,7 +1694,8 @@ layers:
                     filter: { $zoom: [15] }
                     draw:
                         text-blend-order:
-                            priority: 51
+                            priority: 53
+                            visible: global.text_visible_trunk_primary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.0,0.0,0.0]
@@ -2067,7 +1705,8 @@ layers:
                     filter: { $zoom: [16] }
                     draw:
                         text-blend-order:
-                            priority: 51
+                            priority: 53
+                            visible: global.text_visible_trunk_primary
                             #text_source: global.ux_language_text_source_road_ref_and_name
                             font:
                                 fill: [0.0,0.0,0.0]
@@ -2077,7 +1716,8 @@ layers:
                     filter: { $zoom: [17] }
                     draw:
                         text-blend-order:
-                            priority: 51
+                            priority: 53
+                            visible: global.text_visible_trunk_primary
                             #text_source: global.ux_language_text_source_road_ref_and_name
                             font:
                                 fill: [0.0,0.0,0.0]
@@ -2087,7 +1727,8 @@ layers:
                     filter: { $zoom: { min: 18 } }
                     draw:
                         text-blend-order:
-                            priority: 51
+                            priority: 53
+                            visible: global.text_visible_trunk_primary
                             #text_source: global.ux_language_text_source_road_ref_and_name
                             font:
                                 fill: [0.0,0.0,0.0]
@@ -2156,7 +1797,7 @@ layers:
                         filter: { $zoom: [13] }
                         draw:
                             text-blend-order:
-                                priority: 56
+                                priority: 54
                                 visible: global.text_visible_secondary_e
                                 #text_source: global.ux_language_text_source_road_ref_and_name_short
                                 font:
@@ -2167,7 +1808,7 @@ layers:
                         filter: { $zoom: { min: 15 } }
                         draw:
                             text-blend-order:
-                                priority: 56
+                                priority: 54
                                 visible: global.text_visible_secondary_e
                                 #text_source: global.ux_language_text_source_road_ref_and_name_short
                                 font:
@@ -2211,13 +1852,12 @@ layers:
                     draw:
                         text-blend-order:
                             text_source: global.ux_language_text_source_road_ref_and_name_short
-                            visible: global.text_visible_secondary
                 labels-secondary-z13:
                     filter:
                         $zoom: [13]
                     draw:
                         text-blend-order:
-                            priority: 56
+                            priority: 54
                             visible: global.text_visible_secondary_e
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
@@ -2229,7 +1869,7 @@ layers:
                         $zoom: [14]
                     draw:
                         text-blend-order:
-                            priority: 56
+                            priority: 54
                             visible: global.text_visible_secondary_e
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
@@ -2241,7 +1881,8 @@ layers:
                         $zoom: [15]
                     draw:
                         text-blend-order:
-                            priority: 56
+                            priority: 54
+                            visible: global.text_visible_secondary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.10,0.10,0.10]
@@ -2251,7 +1892,8 @@ layers:
                     filter: { $zoom: { min: 16, max: 18 } }
                     draw:
                         text-blend-order:
-                            priority: 56
+                            priority: 54
+                            visible: global.text_visible_secondary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.0,0.0,0.0]
@@ -2261,7 +1903,8 @@ layers:
                     filter: { $zoom: { min: 18 } }
                     draw:
                         text-blend-order:
-                            priority: 56
+                            priority: 54
+                            visible: global.text_visible_secondary
                             #text_source: ref
                             text_source: global.ux_language_text_source_road_ref_and_name
                             font:
@@ -2355,12 +1998,11 @@ layers:
                     draw:
                         text-blend-order:
                             text_source: global.ux_language_text_source_road_ref_and_name_short
-                            visible: global.text_visible_tertiary
                 labels-tertiary-z13:
                     filter: { $zoom: [13] }
                     draw:
                         text-blend-order:
-                            priority: 57
+                            priority: 55
                             visible: global.text_visible_tertiary_e
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
@@ -2371,7 +2013,7 @@ layers:
                     filter: { $zoom: [14] }
                     draw:
                         text-blend-order:
-                            priority: 57
+                            priority: 55
                             visible: global.text_visible_tertiary_e
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
@@ -2382,7 +2024,8 @@ layers:
                     filter: { $zoom: [15] }
                     draw:
                         text-blend-order:
-                            priority: 57
+                            priority: 55
+                            visible: global.text_visible_tertiary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.3,0.3,0.3]
@@ -2392,7 +2035,8 @@ layers:
                     filter: { $zoom: [16] }
                     draw:
                         text-blend-order:
-                            priority: 57
+                            priority: 55
+                            visible: global.text_visible_tertiary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.3,0.3,0.3]
@@ -2402,7 +2046,8 @@ layers:
                     filter: { $zoom: { min: 17, max: 18 } }
                     draw:
                         text-blend-order:
-                            priority: 57
+                            priority: 55
+                            visible: global.text_visible_tertiary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.15,0.15,0.15]
@@ -2412,14 +2057,15 @@ layers:
                     filter: { $zoom: { min: 18 } }
                     draw:
                         text-blend-order:
-                            priority: 57
+                            priority: 55
+                            visible: global.text_visible_tertiary
                             #text_source: global.ux_language_text_source_road_ref_and_name_short
                             font:
                                 fill: [0.15,0.15,0.15]
                                 size: 15px
                                 stroke: { color: [1.00,1.00,1.00], width: 2 }
         minor_road:
-            filter: { kind: minor_road, not: { kind_detail: service }, $zoom: { min: 8 } }
+            filter: { kind: minor_road, not: { kind_detail: service } }
             draw:
                 lines:
                     color: [[12, [0.9,0.9,0.9]], [13, [0.9,0.9,0.9]], [14, [1.0,1.0,1.0]]]
@@ -2521,7 +2167,7 @@ layers:
                 filter: { $zoom: 15 }
                 draw:
                     text-blend-order:
-                        priority: 59
+                        priority: 56
                         visible: global.text_visible_minor_road_e
                         text_source: global.ux_language_text_source
                         font:
@@ -2532,7 +2178,7 @@ layers:
                 filter: { $zoom: 16 }
                 draw:
                     text-blend-order:
-                        priority: 59
+                        priority: 56
                         visible: global.text_visible_minor_road_e
                         text_source: global.ux_language_text_source
                         font:
@@ -2543,7 +2189,7 @@ layers:
                 filter: { $zoom: { min: 17, max: 18 } }
                 draw:
                     text-blend-order:
-                        priority: 59
+                        priority: 56
                         visible: global.text_visible_minor_road_e
                         text_source: global.ux_language_text_source
                         font:
@@ -2554,7 +2200,7 @@ layers:
                 filter: { $zoom: { min: 18 } }
                 draw:
                     text-blend-order:
-                        priority: 59
+                        priority: 56
                         visible: global.text_visible_minor_road
                         text_source: global.ux_language_text_source
                         font:
@@ -2644,7 +2290,7 @@ layers:
                 filter: { $zoom: 17 }
                 draw:
                     text-blend-order:
-                        priority: 60
+                        priority: 57
                         visible: global.text_visible_service_road
                         text_source: global.ux_language_text_source
                         font:
@@ -2656,7 +2302,7 @@ layers:
                 filter: { $zoom: { min: 18 } }
                 draw:
                     text-blend-order:
-                        priority: 60
+                        priority: 57
                         visible: global.text_visible_service_road
                         text_source: global.ux_language_text_source
                         font:
@@ -2664,529 +2310,12 @@ layers:
                             fill: [0.15,0.15,0.15]
                             size: 14px
                             stroke: { color: [1.00,1.00,1.00], width: 2 }
-
-        shields:
+        path:
             filter:
                 all:
-                    - $zoom: { min: 6 }
-                    #
-                    # United State looks great with shield_text alone, but...
-                    #
-                    #shield_text: true    # some roads don't have shield text, deal with that later
-                    #
-                    # Europe doesn't have many network relations set, so we could look for either
-                    # shield_text or ref (with no shield_text) but...
-                    # that makes United States look a bit funky with `(xxx)` and generic shields
-                    # showing up in fields of custom state shields like US:CA and US:NY
-                    #
-                    - function() { return global.sdk_road_shields; }
-                    - any:
-                        - shield_text: true    # some roads don't have shield text, deal with that later
-                        - all:
-                            - shield_text: false    # some roads don't have shield text, deal with that later
-                            - ref: true
-                            - kind_detail: [motorway, trunk, primary, secondary, tertiary]
-            # default
-            draw:
-                icons:
-                    # you need to match any custom shield to the vector tile `network` values
-                    sprite: |
-                        function() {
-                            if( feature.shield_text ) {
-                                return ('generic_shield-' + feature.shield_text.length + 'char');
-                            } else {
-                                return ('generic_shield-' + feature.ref.length + 'char');
-                            }
-                        }
-                    sprite_default: generic_shield_5char
-                    priority: 58
-                    # Size is specified below, and limited to 5 char in another filter
-                    repeat_group: shields
-                    repeat_distance: [[8,90px],[10,40px],[13,30px]]
-                    placement: midpoint
-                    placement_min_length_ratio:
-                        - [8, 0.1]
-                        - [9, 0.25]
-                        - [10, 0.25]
-                        - [11, 0.15]
-                        - [12, 1]
-                        - [13, 1.50]
-                        - [14, 2.0]
-                    cull_from_tile: true
-                    visible: false
-                    text:
-                        offset: [0px, -0.5px]
-                        repeat_distance: 200px
-                        anchor: center
-                        text_source: |
-                            function() {
-                                if( feature.shield_text ) {
-                                    return feature.shield_text;
-                                } else {
-                                    return feature.ref;
-                                }
-                            }
-                        font:
-                            family: Montserrat
-                            fill: [0.308,0.308,0.308]
-                            size: [[7,7px],[12,8px],[15,11px]]
-
-            default_priority_highway:
-                filter:
-                    all:
-                        - kind_detail: motorway
-                        - $zoom: { min: 9 }
-                draw:
-                    icons:
-                        priority: 47
-                        #color: yellow
-                        visible: global.sdk_road_shields
-
-            default_priority_trunk:
-                filter:
-                    all:
-                        - kind_detail: [trunk]
-                        - $zoom: { min: 10 }
-                draw:
-                    icons:
-                        priority: 48
-                        #color: red
-                        visible: global.sdk_road_shields
-            default_priority_primary:
-                filter:
-                    all:
-                        - kind_detail: [primary]
-                        - $zoom: { min: 12 }
-                draw:
-                    icons:
-                        priority: 49
-                        #color: aqua
-                        visible: global.sdk_road_shields
-            default_priority_trunk_secondary:
-                filter:
-                    all:
-                        - kind_detail: [secondary]
-                        - $zoom: { min: 12 }
-                draw:
-                    icons:
-                        priority: 53
-                        #color: blue
-                        visible: global.sdk_road_shields
-            default_priority_trunk_tertiary:
-                filter:
-                    all:
-                        - kind_detail: tertiary
-                        - $zoom: { min: 13 }
-                draw:
-                    icons:
-                        priority: 55
-                        #color: green
-                        visible: global.sdk_road_shields
-
-            width_1char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 1)
-                        } else {
-                            return (feature.ref.length === 1)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[14px,14px]],[13,[16px,16px]],[15,[18px,18px]]]
-            width_2char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 2)
-                        } else {
-                            return (feature.ref.length === 2)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[18px,14px]],[13,[20px,15px]],[15,[24px,18px]]]
-            width_3char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 3)
-                        } else {
-                            return (feature.ref.length === 3)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[25px,14px]],[13,[27px,15px]],[15,[33px,18px]]]
-            width_4char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 4)
-                        } else {
-                            return (feature.ref.length === 4)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[29px,14px]],[13,[31px,15px]],[15,[38px,18px]]]
-                # London sucks
-                early:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        icons:
-                            visible: false
-            width_5char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 5)
-                        } else {
-                            return (feature.ref.length === 5)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[34px,14px]],[13,[37px,15px]],[15,[45px,18px]]]
-                # London sucks
-                early:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        icons:
-                            visible: false
-            # this is kinda a hack
-            width_longggggg:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length > 5)
-                        } else {
-                            return (feature.ref.length > 5)
-                        }
-                    }
-                draw:
-                    icons:
-                        visible: false
-            #
-            # Now for the good stuff
-            #
-            legit-shields:
-                filter: { shield_text: true }
-                # draw:
-                #     icons:
-                #         color: pink
-
-                # US Interstate roads
-                US-I:
-                    filter:
-                        network: 'US:I'
-                    draw:
-                        icons:
-                            # you need to match any custom shield to the vector tile `network` values
-                            sprite: function() { return (feature.network + '-' + feature.shield_text.length + 'char'); }
-                            priority: 46
-                            visible: global.sdk_road_shields
-                            text:
-                                offset: [0px, 0.5px]
-                                font:
-                                    fill: [0.308,0.308,0.308]
-                                    size: [[7,8px],[13,9px],[15,11px]]
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[15px,18px]],[13,[17px,20px]],[15,[22px,25px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[18px,18px]],[13,[20px,20px]],[15,[25px,25px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[23px,18px]],[13,[26px,20px]],[15,[33px,25px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[25px,18px]],[13,[27px,20px]],[15,[35px,25px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[26px,18px]],[13,[30px,20px]],[15,[38px,25px]]]
-                # US Federal Routes
-                US-US:
-                    filter:
-                        network: ['US:US','US:US:Business', 'US:US:Truck', 'US:US:Alternate']
-                        $zoom: { min: 7 }
-                    draw:
-                        icons:
-                            # you need to match any custom shield to the vector tile `network` values
-                            sprite: |
-                                function() { return ('US:US-' + feature.shield_text.length + 'char'); }
-                            priority: 47
-                            cull_from_tile: true
-                            visible: global.sdk_road_shields
-                            text:
-                                offset: [0px, -0.7px]
-                                font:
-                                    fill: [0.380,0.318,0.312]
-                                    size: [[7,8px],[13,9px],[15,11px]]
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[15px,17px]],[13,[17px,19px]],[15,[22px,24px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[18px,17px]],[13,[20px,19px]],[15,[26px,24px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[22px,17px]],[13,[25px,19px]],[15,[34px,25px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[25px,17px]],[13,[29px,19px]],[15,[39px,25px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[27px,17px]],[13,[30px,19px]],[15,[41px,25px]]]
-                # US State Routes
-                # US-states:
-                #     # Match state highways: `US:??`
-                #     filter: |
-                #         function() {
-                #             return feature.shield_text &&
-                #                 /^US:(?!US)\w\w$/.test(feature.network)
-                #         }
-                #     draw:
-                #         icons:
-                #             # you need to match any custom shield to the vector tile `network` values
-                #             #priority: 48
-                #             visible: global.sdk_road_shields
-                US-CA:
-                    # Match California state highways: `US:CA`
-                    filter: |
-                        function() {
-                            return feature.shield_text &&
-                                /^US:CA$/.test(feature.network)
-                        }
-                    draw:
-                        icons:
-                            sprite: function() { return (feature.network + '-' + feature.shield_text.length + 'char'); }
-                            #priority: 48
-                            text:
-                                offset: [0px, 1px]
-                                font:
-                                    fill: [0.308,0.308,0.308]
-                                    size: [[7,7px],[13,9px],[15,10px]]
-                    motorway:
-                        filter: { kind_detail: [motorway], $zoom: [7,8] }
-                        draw:
-                            icons:
-                                visible: global.sdk_road_shields
-                    trunk:
-                        filter: { kind_detail: [trunk], $zoom: [8,9] }
-                        draw:
-                            icons:
-                                visible: global.sdk_road_shields
-                    primary:
-                        filter: { kind_detail: primary, $zoom: [10,11] }
-                        draw:
-                            icons:
-                                visible: global.sdk_road_shields
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[14px,16px]],[13,[15px,18px]],[15,[18px,21px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[18px,18px]],[13,[20px,20px]],[15,[23px,23px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[21px,18px]],[13,[24px,20px]],[15,[28px,23px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[24px,18px]],[13,[26px,20px]],[15,[31px,23px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[25px,18px]],[13,[27px,20px]],[15,[32px,23px]]]
-                US-NY:
-                    # Match New York state highways: `US:NY`
-                    filter: |
-                        function() {
-                            return feature.shield_text &&
-                                /^US:NY$/.test(feature.network)
-                                /* (/^US:NY$/.test(feature.network) || /^NY:US$/.test(feature.network)) */
-                        }
-                    draw:
-                        icons:
-                            sprite: |
-                                function() { return ( 'US:NY-' + feature.shield_text.length + 'char'); }
-                            text:
-                                # offset: [0px, 1px]
-                                font:
-                                    fill: [0.308,0.308,0.308]
-                                    size: [[7,7px],[13,9px],[15,10px]]
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[13px,17px]],[13,[15px,19px]],[15,[18px,22px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[17px,17px]],[13,[19px,19px]],[15,[22px,22px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[20px,17px]],[13,[22px,19px]],[15,[27px,22px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[21px,17px]],[13,[24px,19px]],[15,[29px,22px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[22px,17px]],[13,[25px,19px]],[15,[30px,22px]]]
-                US-PA:
-                    # Match Pennsylvania state highways
-                    filter: |
-                        function() {
-                            return feature.shield_text &&
-                                /^US:PA$/.test(feature.network)
-                        }
-                    draw:
-                        icons:
-                            sprite: |
-                                function() { return ( 'US:PA-' + feature.shield_text.length + 'char'); }
-                            text:
-                                offset: [0px, 1px]
-                                font:
-                                    fill: [0.308,0.308,0.308]
-                                    size: [[7,7px],[13,9px],[15,10px]]
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[13px,17px]],[13,[15px,19px]],[15,[18px,22px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[17px,17px]],[13,[19px,19px]],[15,[22px,22px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[21px,17px]],[13,[24px,19px]],[15,[28px,22px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[22px,17px]],[13,[25px,19px]],[15,[30x,22px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[24px,17px]],[13,[27px,19px]],[15,[32px,22px]]]
-                # USA County Routes
-                US-counties:
-                    # Match state highways: `US:??:*`
-                    #
-                    # this is very USA specific
-                    #
-                    # filter: |
-                    #     function() {
-                    #         return feature.shield_text &&
-                    #             /^US:(?!US)\w\w:.*$/.test(feature.network)
-                    #     }
-                    #
-                    # this generic for any country with 3rd level networks (like county routes in USA)
-                    # BEWARE:
-                    # US:US:Business  about 150
-                    # US:US:Truck
-                    # US:US:Alternate
-    #
-                    # STATE ROUTE
-                    # ??:??:Loop  about 200
-                    # ??:??:Spur  about 200
-                    # ??:??:Business   about 100
-    #
-                    # STATE TEXAS SPECIAL ROUTE
-                    # US:TX:FM -- probably just state? there are 3k of these
-                    #
-                    #
-                    filter: |
-                        function() {
-                            return feature.shield_text &&
-                                /^\w+:\w+:(!Alternate).+$/.test(feature.network) &&
-                                $zoom > 10
-                        }
-                    draw:
-                        icons:
-                            # you need to match any custom shield to the vector tile `network` values
-                            sprite: function() { return ('county_shield-' + feature.shield_text.length + 'char'); }
-                            #color: pink
-                            #priority: 19
-                            visible: global.sdk_road_shields
-                            text:
-                                font:
-                                    fill: [0.508,0.508,0.508]
-                                    #size: [[11,7px],[15,10px]]
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[14px,14px]],[13,[16px,16px]],[15,[18px,18px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[16px,14px]],[13,[18px,15px]],[15,[22px,18px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[20px,14px]],[13,[21px,15px]],[15,[26px,18px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[25px,14px]],[13,[28px,15px]],[15,[34px,18px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[30px,14px]],[13,[33px,15px]],[15,[40px,18px]]]
-        path:
-            filter:
-                all:
-                    - kind: [path, portage_way]
-                not:
-                    - kind_detail: [steps, track, pier]
+                    - kind: [path, portage_way]
+                not:
+                    - kind_detail: [steps, track, pier]
             draw:
                 lines:
                     color: [[14, [0.97,0.97,0.97]],[16,[0.96,0.96,0.96]]]
@@ -3287,7 +2416,7 @@ layers:
                 filter: { $zoom: { min: 17 } }
                 draw:
                     text-blend-order:
-                        priority: 61
+                        priority: 58
                         visible: global.text_visible_path
                         text_source: global.ux_language_text_source
                         font:
@@ -3333,7 +2462,7 @@ layers:
                     - kind: path
                     - kind_detail: steps
             draw:
-                dashed_steps:
+                dashedline:
                     order: global.feature_order
                     color: [0.97,0.97,0.97]
                     width: [[14,0.6px],[16,2px],[17,4px],[18,5px],[19,8px],[20,10px]]
@@ -3343,21 +2472,21 @@ layers:
             in_park:
                 filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden] }
                 draw:
-                    dashed_steps:
+                    dashedline:
                         color: [1.0,1.0,1.0]
                         outline:
                             color: [0.867,0.867,0.867]
             in_university:
                 filter: { landuse_kind: university }
                 draw:
-                    dashed_steps:
+                    dashedline:
                         color: [1.0,1.0,1.0]
                         outline:
                             color: [0.867,0.867,0.867]
             in_hospital:
                 filter: { landuse_kind: hospital }
                 draw:
-                    dashed_steps:
+                    dashedline:
                         color: [1.0,1.0,1.0]
                         outline:
                             color: [0.867,0.867,0.867]
@@ -3365,7 +2494,7 @@ layers:
                 filter: { $zoom: { min: 17 } }
                 draw:
                     text-blend-order:
-                        priority: 62
+                        priority: 59
                         visible: global.text_visible_steps
                         text_source: global.ux_language_text_source
                         font:
@@ -3382,7 +2511,7 @@ layers:
                     color: '#909090'
                     width: [[13,0px],[14,0.5px],[15, 1px], [16, 1.5px], [18, 3m]]
                 text-blend-order:
-                    priority: 60
+                    priority: 18
                     visible: true
                     font:
                         fill: global.text_fill_piste
@@ -3437,26 +2566,27 @@ layers:
             filter: { kind: racetrack }
             draw:
                 lines:
+                    interactive: true
                     cap: round
                     join: round
                     color: [0.600,0.667,0.627]
                     width: [[13,0.5px],[14,1px],[15, 1px], [16, 1.5px], [18, 3px], [19, 5px]]
         airport-lines:
-            filter: { kind: aeroway, kind_detail: [runway,taxiway] }
+            filter: { kind: minor_road, aeroway: [runway,taxiway] }
             draw:
                 lines:
                     color: [[10,[0.4,0.4,0.4]],[11,[0.50,0.50,0.50]],[12,[0.7,0.7,0.7]],[13,[0.75,0.75,0.75]],[14,[0.95,0.95,0.95]]]
                     cap: butt
-                    width: [[10,0.75px],[11,1.25px],[12,2px],[13,4px],[14,8px],[15,16px],[16,32px],[17,60m]]
+                    width: [[9,0px],[10,0.75px],[11,1.25px],[12,2px],[13,4px],[14,8px],[15,16px],[16,32px],[17,60m]]
                     # outline:
                     #     color: [17,[0.95,0.95,0.95]]
                     #     width: [17,[60m]]
             # Features come in at zoom 9, but include mostly minor airports without POIs until z13
             early:
-               filter: { $zoom: { max: 12 }, not: { landuse_kind: [aerodrome, runway, taxiway] } }
-               draw:
-                   lines:
-                       visible: false
+                filter: { $zoom: { max: 12 }, not: { landuse_kind: [aerodrome, runway, taxiway] } }
+                draw:
+                    lines:
+                        visible: false
             not-round:
                 filter: { $zoom: { min: 17 } }
                 draw:
@@ -3487,6 +2617,7 @@ layers:
             filter: { kind: aerialway }
             draw:
                 lines:
+                    interactive: true
                     color: '#444'
                     width: [[14, 0.5px], [15, 1.0px], [16, 2m]]
             gondola_cable_car:
@@ -3511,7 +2642,7 @@ layers:
                 filter: { $zoom: { min: 14 } }
                 draw:
                     text-blend-order:
-                        priority: 63
+                        priority: 59
                         visible: global.text_visible_aerialway
                         text_source: global.ux_language_text_source
                         font:
@@ -3547,6 +2678,7 @@ layers:
             filter: { kind: rail, not: { railway: [subway,light_rail,tram] } }
             draw:
                 lines:
+                    interactive: true
                     order: global.feature_order
                     color: [0.588,0.671,0.698]
                     width: [[12,0px],[13,0.25px],[14,0.4px],[15,0.75px],[16,0.75px],[18,1m]]
@@ -3572,7 +2704,7 @@ layers:
                         lines:
                             outline:
                                 # except bridges and tunnels, their outlines should also self-sort
-                                order: function() { return feature.sort_rank || 305; }
+                                order: function() { return feature.sort_key || 305; }
 
     buildings:
         data: { source: mapzen, layer: buildings }
@@ -3613,6 +2745,7 @@ layers:
 #                           }
 #                       }
 #                   }
+                interactive: true
             lines:
                 style: lines
                 order: 330
@@ -3620,6 +2753,11 @@ layers:
                 color: [[13,[0.70,0.70,0.70]],[17,[0.65, 0.65, 0.65]]]
                 width: [[13, 0.55px], [15, 0.65px], [16,0.75px], [18, 1.25px]]
 
+        # turn interactive feature selection on for buildings with names
+        interactive:
+            filter: { name: true }
+            draw: { polygons: { interactive: true } }
+
         # building footprints, pre-extrusion
         footprints:
             filter:
@@ -3640,7 +2778,7 @@ layers:
             extrude:
                 filter:
                     all:
-                        - function() { return global.sdk_building_extrude; }
+                        - function() { return global.building_extrude; }
                         - any:
                             - { $zoom: 15, height: { min: 190 } }
                             - { $zoom: 15, area: { min: 5000 } }
@@ -3656,22 +2794,15 @@ layers:
                         order: 438
                         style: building-grid
                         extrude: global.building_extrude_height
+                        color: [0.892,0.880,0.878]
                     lines:
                         order: 439
                         style: building-lines
                         extrude: global.building_extrude_height
-                # NOTE: This is a hack to re-enable the building colors per landuse_kind
-                # Earlier versions before October 2016 didn't need this hack
-                not_landuse:
-                    filter: { not: { landuse_kind: [station, retail, aerodrome, runway, taxiway, park,forest,nature_reserve,conservation,golf_course,garden, university,school, hospital] } }
-                    draw:
-                        polygons:
-                            color: [0.892,0.880,0.878]
 
         # landuse-specific rules
         in_park:
-            filter:
-                landuse_kind: [park,forest,nature_reserve,conservation,golf_course,garden]
+            filter: { landuse_kind: [park,forest,nature_reserve,conservation,golf_course,garden] }
             draw:
                 polygons:
                     color: [0.864,0.910,0.905]
@@ -3724,15 +2855,16 @@ layers:
 
         transit-overlay-station-buildings:
             filter:
-                all:
+                any:
                     - landuse_kind: [station]
-                    - function() { return global.sdk_transit_overlay; }
             draw:
                 polygons:
+                    visible: global.sdk_transit_overlay
                     color: '#bdadbf'
                     order: 500
                     #extrude: function() { return feature.height || 20; }
                 outline:
+                    visible: global.sdk_transit_overlay
                     style: lines
                     order: 501
                     color: '#d534df'
@@ -3746,7 +2878,6 @@ layers:
                     - $geometry: point
                     - not: { location: underground, kind: address }
                     - name: true
-                    - function() { return global.text_visible_building; }
     #                - kind: [false, building, university, college, school, kindergarten]
                 any:
                     - { $zoom: [16], area: { min: 5000 } }
@@ -3764,8 +2895,10 @@ layers:
             draw:
                 text-blend-order:
                     text_source: global.ux_language_text_source
+                    interactive: true
                     move_into_tile: true
                     priority: 70
+                    visible: global.text_visible_building
                     order: 7
                     font:
                         fill: '#666'
@@ -3803,11 +2936,12 @@ layers:
                 any:
                     - kind: address
                     - { label_position: true, addr_housenumber: true, name: false }
-                all:
-                    - function() { return global.text_visible_address; }
             draw:
                 text-blend-order:
+                    text_source: global.ux_language_text_source
+                    interactive: true
                     order: 7
+                    visible: global.text_visible_address
                     text_source: addr_housenumber
                     font:
                         fill: global.text_fill_address
@@ -3821,6 +2955,7 @@ layers:
         # country subdivisions (states, provinces)
         draw:
             lines:
+                interactive: true
                 order: global.feature_order
 #                color: red
 #                width: [[9, 1px], [14, 2px], [16, 3px], [17, 8m]]
@@ -3832,27 +2967,12 @@ layers:
             draw:
                 lines:
                     color: global.country_boundary
-                    width: [[1, 0.5px], [2, 1.0px], [4, 1.5px], [8, 2.5px], [14, 3.5px], [16, 4.5px], [17, 14m]]
+                    width: [[1, 0.5px], [2, 1.0px], [4, 1.5px], [9, 2.5px], [14, 3.5px], [16, 4.5px], [17, 14m]]
             water:
                 filter: { maritime_boundary: true }
                 draw:
                     lines:
                         visible: false
-            labels-z9-up:
-                filter: { name: true, $zoom: { min: 9 }, not: { maritime_boundary: true } }
-                draw:
-                    text-blend-order:
-                        priority: 2
-                        visible: global.text_visible_admin
-                        text_source: global.ux_language_text_source_boundary_lines
-                        text_wrap: 100px
-                        font:
-                            family: Varela
-                            size: 9px
-                            weight: 300
-                            fill: [0.25,0.25,0.25]
-                            # stroke: { color: global.text_stroke, width: 4 }
-                            transform: uppercase
         other_country_boundary_disputed_etc:
             filter: { kind: [disputed, indefinite, indeterminate, lease_limit, line_of_control, overlay_limit] }
             draw:
@@ -3860,16 +2980,6 @@ layers:
                     order: global.feature_order
                     color: global.country_boundary
                     width: [[1, 0.2px], [2, 0.5px], [4, 1.0px], [9, 1.5px], [14, 2.5px], [16, 3.5px], [17, 10m]]
-            disputed:
-                filter: { kind: [disputed, line_of_control] }
-                draw:
-                    dashed:
-                        visible: false
-                    dashed_big:
-                        order: global.feature_order
-                        color: global.country_boundary
-                        #width: [[1, 0.2px], [2, 0.5px], [4, 1.0px], [9, 1.5px], [14, 2.5px], [16, 3.5px], [17, 10m]]
-                        width: [[1, 0.5px], [2, 1.0px], [4, 1.5px], [9, 2.5px], [14, 3.5px], [16, 4.5px], [17, 14m]]
         region:
             filter:
                 any:
@@ -3878,7 +2988,7 @@ layers:
             draw:
                 lines:
                     color: global.region_boundary
-                    width: [[0, 0.5px], [2, 1.0px], [5, 1.25px], [6, 1.5px], [7, 1.75px], [8, 2.0px], [9, 3.5px], [14, 5.5px], [16, 6.5px], [17, 16m]]
+                    width: [[0, 0.5px], [2, 1.0px], [5, 1.25px], [6, 1.5px], [7, 1.75px], [9, 3.5px], [14, 5.5px], [16, 6.5px], [17, 16m]]
             water:
                 filter: { maritime_boundary: true }
                 draw:
@@ -3889,23 +2999,6 @@ layers:
                 draw:
                     lines:
                         visible: false
-            labels-z9-up:
-                filter: { name: true, $zoom: { min: 9 }, not: { maritime_boundary: true } }
-                draw:
-                    text-blend-order:
-                        priority: 3
-                        visible: global.text_visible_admin
-                        text_source: global.ux_language_text_source_boundary_lines
-                        text_wrap: 100px
-                        offset: 10px
-                        anchor: top
-                        font:
-                            family: Varela
-                            size: 9px
-                            weight: 200
-                            fill: [0.4,0.4,0.4]
-                            # stroke: { color: global.text_stroke, width: 4 }
-                            transform: uppercase
         city_walls:
             filter: { kind: city_wall }
             draw:
@@ -3933,733 +3026,1812 @@ layers:
 
     places:
         data: { source: mapzen, layer: places }
-        filter:
-            name: true
         draw:
             icons:
                 text:
                     text_source: global.ux_language_text_source
                     visible: false    # labels are enabled by each layer below
-                    buffer: 3px
                     font:
-                        family: Varela
+                        family: global.text_font_family
+                        # weight: 500
                         fill: global.text_fill
-            # NOTE: This is a hack for localities because of an icon & text bug, see note below
             text-blend-order:
                 text_source: global.ux_language_text_source
                 visible: false    # labels are enabled by each layer below
-                buffer: 3px
                 font:
-                    family: Varela
+                    family: global.text_font_family
+                    # weight: 500
                     fill: global.text_fill
-            # END NOTE
 
-        country:
+        continent:
+            filter: { name: true, kind: [continent], $zoom: {max: 5} }
+            draw:
+                text-blend-order:
+                    visible: global.text_visible_continent
+                    font:
+                        size: 14px
+                        weight: 700
+                        # stroke: { color: global.text_stroke, width: 4 }
+                        transform: uppercase
+
+        country-z2:
             filter:
-                kind: country
-                $zoom: { min: 2, max: 9 }
+                all:
+                    - kind: [country]
+                    - $zoom: [2]
+                    - name: ["United States of America","Brasil","中华人民共和国","Россия","Canada","Kalaallit Nunaat","Ísland","Australia","India","日本","Guam","Indonesia","South Africa","مصر","Nigeria","Kenya"]
             draw:
                 text-blend-order:
                     priority: 3
                     visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source
                     font:
-                        fill: [[2,[0.357,0.243,0.184]],[6,[0.604,0.437,0.427]]]
+                        fill: [0.30,0.30,0.30]
+                        weight: 400
+                        size: 10px
                         transform: uppercase
-            country-z2-z3:
-                filter:
-                    $zoom: [2,3]
-                draw:
-                    text-blend-order:
-                        priority: 10
-                        buffer: 10px
-                        font:
-                            size: 10px
-                early-ones-z2:
-                    filter:
-                        $zoom: [2]
-                        not: { name: [United States of America,Brasil,中华人民共和国,Россия,Canada,Kalaallit Nunaat,Ísland,Australia,India,日本,Guam,Indonesia,South Africa,مصر,Nigeria,Kenya] }
-                    draw:
-                        text-blend-order:
-                            visible: false
-                early-ones-z3:
-                    filter:
-                        $zoom: [3]
-                        name: [Nederland,Luxembourg,Liechtenstein,San Marino,Civitatis Vaticanæ,Crna Gora,Македонија,The Gambia,Burundi,Swaziland,الإمارات العربية المتحدة,العراق,Singapore,El Salvador,Belize,Trinidad and Tobago, Saint Lucia, Montserrat,Anguilla,República Dominicana,Bahamas,British Virgin Islands,Antigua and Barbuda,Grenada,Sint Maarten,Saint Kitts and Nevis,Cayman Islands,België - Belgique - Belgien,Deutschland,España]
-                    draw:
-                        text-blend-order:
-                            visible: false
-            country-z4:
-                filter:
-                    $zoom: [4]
+        country-z3:
+            filter: { name: true, population: true, kind: [country], $zoom: [3] }
+            draw:
+                text-blend-order:
+                    priority: 3
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source
+                    font:
+                        fill: [0.20,0.20,0.20]
+                        size: 11px
+                        weight: 600
+                        # stroke: { color: global.text_stroke, width: 4 }
+                        transform: uppercase
+    #            icons:
+    #                size: [[13, 12px], [15, 18px]]
+    #                interactive: true
+    #                sprite: global.townspot_sprite
+            early-ones:
+                # US, Brazil, China, Russia, Canada, Greenland, Iceland, Australia, India, Japan, Guam, Indonesia, South Africa, Egypt, Nigeria, Kenya
+                filter: { not: { name: ["United States of America","Brasil","中华人民共和国","Россия","Canada","Kalaallit Nunaat","Ísland","Australia","India","日本","Guam","Indonesia","South Africa","مصر","Nigeria","Kenya"] }, $zoom: {min: 3, max: 4} }
                 draw:
                     text-blend-order:
-                        buffer: 10px
-                        priority: 8
-                        font:
-                            size: 11px
-                early-ones-z4:
-                    filter:
-                        name: [Nederland,Luxembourg,Liechtenstein,San Marino,Civitatis Vaticanæ,Crna Gora,Македонија,The Gambia,Burundi,Swaziland,الإمارات العربية المتحدة,العراق,Singapore,El Salvador,Belize,Trinidad and Tobago, Saint Lucia, Montserrat,Anguilla,República Dominicana,Bahamas,British Virgin Islands,Antigua and Barbuda,Grenada,Sint Maarten,Saint Kitts and Nevis,Cayman Islands,België - Belgique - Belgien,Deutschland,España,Magyarország,Österreich,Polska,Хуссар Ирыстон,Аҧсны - Абхазия]
-                    draw:
-                        text-blend-order:
-                            visible: false
-            country-z5:
-                filter:
-                    $zoom: [5]
+                        visible: false
+        country-z4:
+            filter: { name: true, population: true, kind: [country], $zoom: [4] }
+            draw:
+                text-blend-order:
+                    priority: 3
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source
+                    font:
+                        size: 12px
+                        weight: 600
+                        fill: [0.40,0.40,0.40]
+                        # stroke: { color: global.text_stroke, width: 4 }
+                        transform: uppercase
+    #            icons:
+    #                size: [[13, 12px], [15, 18px]]
+    #                interactive: true
+    #                sprite: global.townspot_sprite
+            early-ones-z4:
+                filter: { name: [Nederland,Luxembourg,Liechtenstein,San Marino,Civitatis Vaticanæ,Crna Gora,Македонија,The Gambia,Burundi,Swaziland,الإمارات العربية المتحدة,العراق,Singapore,El Salvador,Belize,Trinidad and Tobago, Saint Lucia, Montserrat,Anguilla,República Dominicana,Bahamas,British Virgin Islands,Antigua and Barbuda,Grenada,Sint Maarten,Saint Kitts and Nevis,Cayman Islands,België - Belgique - Belgien], $zoom: {min: 4, max: 5} }
                 draw:
                     text-blend-order:
-                        priority: 8
-                        font:
-                            size: 13px
-                early-ones-z5:
+                        visible: false
+        country-z5:
+            filter:
+                all:
+                    - name: true
+                    - population: true
+                    - kind: [country]
+                    - $zoom: [5]
+                any:
+                    - { population: { min: 5000000 } }
+            draw:
+                text-blend-order:
+                    priority: 3
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source
+                    font:
+                        size: 13px
+                        weight: 400
+                        fill: [0.25,0.25,0.25]
+                        # stroke: { color: global.text_stroke, width: 4 }
+                        transform: uppercase
+    #            icons:
+    #                size: [[13, 12px], [15, 18px]]
+    #                interactive: true
+    #                sprite: global.townspot_sprite
+            early-ones-z5:
+                filter: { name: [Luxembourg,Liechtenstein,San Marino,Civitatis Vaticanæ,El Salvador,Belize,België - Belgique - Belgien], $zoom: {min: 5, max: 6} }
+                draw:
+                    text-blend-order:
+                        visible: false
+        country-z6:
+            # South Ossetia and Abkhazia aren't countries (they are disputed areas)
+            filter: { name: true, kind: [country], $zoom: [6] }
+            draw:
+                text-blend-order:
+                    priority: 3
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source
+                    font:
+                        size: 14px
+                        weight: 600
+                        fill: [0.25,0.25,0.25]
+                        # stroke: { color: global.text_stroke, width: 4 }
+                        transform: uppercase
+            small-ones-z6:
+                filter: { name: [Luxembourg,Liechtenstein,San Marino,Civitatis Vaticanæ,België - Belgique - Belgien,Хуссар Ирыстон,Аҧсны - Абхазия], $zoom: {min: 6, max: 7} }
+                draw:
+                    text-blend-order:
+                        visible: false
+        country-z7:
+            # South Ossetia and Abkhazia aren't countries (they are disputed areas)
+            filter: { name: true, kind: [country], $zoom: { min: 7, max: 9 } }
+            draw:
+                text-blend-order:
+                    priority: 3
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source
+                    font:
+                        size: 16px
+                        weight: 600
+                        fill: [0.25,0.25,0.25]
+                        # stroke: { color: global.text_stroke, width: 4 }
+                        transform: uppercase
+            small-ones-z7:
+                filter: { name: [Liechtenstein,San Marino,Civitatis Vaticanæ,Хуссар Ирыстон,Аҧсны - Абхазия], $zoom: {min: 7, max: 8} }
+                draw:
+                    text-blend-order:
+                        visible: false
+
+        region-z4:
+            filter: { name: true, kind: [region], $zoom: [4], not: { name: ["Western Cape","Eastern Cape","Northern Cape","North West","Limpopo","KwaZulu-Natal","Hamburg","Freie und Hansestadt Hamburg","Neuchâtel","Nordrhein-Westfalen","Haute-Normandie","Baden-Württemberg","Bayern","Sachsen-Anhalt","Berlin","Mecklenburg-Vorpommern","Schleswig-Holstein","Brandenburg","Niedersachsen","Saarland","Thüringen","Hessen","Sachsen"] } }
+            draw:
+                text-blend-order:
+                    priority: 14
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source_short
+                    font:
+                        size: 10px
+                        weight: 300
+                        fill: [0.3,0.3,0.3]
+
+        region-z5:
+            filter: { name: true, kind: [region], $zoom: [5], not: { name: ["Western Cape","Eastern Cape","Northern Cape","North West","Limpopo","KwaZulu-Natal","Hamburg","Freie und Hansestadt Hamburg","Neuchâtel","Nordrhein-Westfalen","Haute-Normandie","Baden-Württemberg","Bayern","Sachsen-Anhalt","Berlin","Mecklenburg-Vorpommern","Schleswig-Holstein","Brandenburg","Niedersachsen","Saarland","Thüringen","Hessen","Sachsen"] } }
+            draw:
+                text-blend-order:
+                    priority: 14
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source_short
+                    font:
+                        size: 13px
+                        weight: 300
+                        fill: [0.3,0.3,0.3]
+
+        region-z6:
+            filter: { name: true, kind: [region], $zoom: [6], not: { name: ["Western Cape","Eastern Cape","Northern Cape","North West","Limpopo","KwaZulu-Natal","Hamburg","Freie und Hansestadt Hamburg","Neuchâtel","Nordrhein-Westfalen","Haute-Normandie","Baden-Württemberg","Bayern","Sachsen-Anhalt","Berlin","Mecklenburg-Vorpommern","Schleswig-Holstein","Brandenburg","Niedersachsen","Saarland","Thüringen","Hessen","Sachsen"] } }
+            draw:
+                text-blend-order:
+                    priority: 14
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source_short
+                    font:
+                        size: 15px
+                        weight: 300
+                        fill: [0.4,0.4,0.4]
+
+        region:
+            filter: { name: true, kind: [region], $zoom: [7,8] }  # someday: province
+            draw:
+                text-blend-order:
+                    priority: 14
+                    visible: global.text_visible_admin
+                    text_source: global.ux_language_text_source_short_proxy_name
+                    font:
+                        size: 14px
+                        weight: 300
+                        fill: [0.3,0.3,0.3]
+                        #stroke: { color: global.text_stroke, width: 4 }
+                        transform: uppercase
+    #            icons:
+    #                size: [[13, 12px], [15, 18px]]
+    #                interactive: true
+    #                sprite: global.townspot_sprite
+            pesky:
+                filter: { name: ["Western Cape","Eastern Cape","Northern Cape","North West","Limpopo","KwaZulu-Natal","Hamburg","Freie und Hansestadt Hamburg","Neuchâtel","Nordrhein-Westfalen","Haute-Normandie","Baden-Württemberg","Bayern","Sachsen-Anhalt","Berlin","Mecklenburg-Vorpommern","Schleswig-Holstein","Brandenburg","Niedersachsen","Saarland","Thüringen","Hessen","Sachsen"], $zoom: [7] }
+                draw:
+                    text-blend-order:
+                        visible: false
+#            early-provinces:
+#                filter: { kind: province, $zoom: [7] }
+#                draw:
+#                    text-blend-order:
+#                        visible: false
+            small-ones:
+                filter: { name: ["Delaware","New Jersey","Connecticut","Rhode Island","Massachusetts","New Hampshire","Vermont"], $zoom: [7] }
+                draw:
+                    text-blend-order:
+                        text_source: global.ux_language_text_source_abbreviation
+                        font: { transform: uppercase }
+
+        populated-places:
+            filter: { kind: locality }
+            draw:
+                icons:
+                    interactive: true
+                    priority: 5
+                    # debug testing
+                    #collide: false
+                    text:
+                        interactive: true
+                        # debug testing
+                        #collide: false
+
+            populated-places-natural-earth-z2:
+                filter: { $zoom: [2] }
+                draw:
+                    icons:
+                        size: 5px
+                        visible: global.icon_visible_populated_places
+                        sprite: townspot-s-rev
+                        text:
+                            visible: global.text_visible_populated_places
+                            font:
+                                size: 10px
+                                fill: global.text_fill
+                                # stroke: { color: global.text_stroke, width: 4 }
+
+            populated-places-natural-earth-z3:
+                filter: { $zoom: [3] }
+                z3places-1:
+                    filter: { min_zoom: [2] }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 11px
+                                    fill: global.text_fill
+                                    # stroke: { color: global.text_stroke, width: 4 }
+                z3places-2:
+                    filter: { min_zoom: [3] }
+                    draw:
+                        icons:
+                            priority: 7
+                            size: 5px
+                            sprite: townspot-s-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 9px
+                                    fill: global.text_fill
+                                    # stroke: { color: global.text_stroke, width: 4 }
+
+            populated-places-natural-earth-z4:
+                filter: { $zoom: [4] }
+                z4places-1:
+                    filter: { min_zoom: [2] }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+                                    fill: global.text_fill
+                                    # stroke: { color: global.text_stroke, width: 4 }
+
+                z4places-2:
+                    filter: { min_zoom: [3,4] }
+                    draw:
+                        icons:
+                            priority: 7
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 10px
+                                    fill: global.text_fill
+                                    # stroke: { color: global.text_stroke, width: 4 }
+
+            populated-places-natural-earth-z5:
+                filter: { $zoom: [5] }
+                z5places-1:
+                    filter: { min_zoom: [2,3] }
+                    draw:
+                        icons:
+                            priority: 7
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                priority: 5
+                                size: 8px
+                                sprite: capital-l
+
+                z5places-2:
+                    filter: { min_zoom: [4] }
+                    draw:
+                        icons:
+                            priority: 11
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 11px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                priority: 9
+                                size: 6px
+                                sprite: capital-m
+
+                z5places-3:
+                    filter: { min_zoom: [5] }
+                    draw:
+                        icons:
+                            priority: 17
+                            size: 5px
+                            sprite: townspot-s-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.25,0.25,0.25]
+                                    size: 10px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                priority: 15
+                                size: 6px
+                                sprite: capital-m
+
+            populated-places-natural-earth-z6:
+                filter: { name: true, source: naturalearthdata.com, $zoom: [6] }
+                z6places-1:
+                    filter: { min_zoom: [2,3] }
+                    draw:
+                        icons:
+                            priority: 7
+                            size: 8px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-l-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: global.text_fill
+                                    size: 15px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-l
+                                size: 8px
+                                priority: 5
+
+                z6places-2:
+                    filter: { min_zoom: [4,5] }
+                    draw:
+                        icons:
+                            priority: 11
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: global.text_fill
+                                    size: 12px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 6px
+                                sprite: capital-m
+                                priority: 9
+
+                z6places-3:
+                    filter: { min_zoom: [6] }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 15
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.25,0.25,0.25]
+                                    size: 10px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 6px
+                                sprite: capital-m
+                                priority: 13
+
+            populated-places-natural-earth-z7:
+                filter: { name: true, source: naturalearthdata.com, $zoom: [7] }
+                z7places-1:
+                    filter: { min_zoom: [2,3] }
+                    draw:
+                        icons:
+                            size: 8px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-l-rev
+                            priority: 7
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: global.text_fill
+                                    size: 16px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 8px
+                                sprite: capital-l
+                                priority: 5
+
+                z7places-2:
+                    filter: { min_zoom: [4,5,6] }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 13
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: global.text_fill
+                                    size: 13px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 8px
+                                sprite: capital-l
+                                priority: 11
+
+                z7places-3:
+                    filter: { min_zoom: [6,7] }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 17
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.25,0.25,0.25]
+                                    size: 11px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 6px
+                                sprite: capital-m
+                                priority: 15
+
+            populated-places-osm-z8:
+                filter:
+                    all:
+                        - source: openstreetmap.org
+                        - $zoom: [8]
+                z8places-1:
+                    filter:
+                        any:
+                            - { population: { min: 1000000 } }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 7
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 16px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 8px
+                                sprite: capital-l
+                                priority: 5
+                z8places-2:
+                    filter:
+                        any:
+                            - { population: { min: 150000, max: 999999 } }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 11
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 6px
+                                sprite: capital-m
+                                priority: 9
+
+                z8places-3:
+                    filter:
+                        any:
+                            - { population: { min: 85000, max: 149999 } }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 15
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.25,0.25,0.25]
+                                    size: 11px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 6px
+                                sprite: capital-m
+                                priority: 13
+
+                z8places-4:
                     filter:
-                        # South Ossetia and Abkhazia aren't countries (they are disputed areas)
-                        - name: [Luxembourg,Liechtenstein,San Marino,Civitatis Vaticanæ,El Salvador,Belize,België - Belgique - Belgien,"Хуссар Ирыстон - Южная Осетия","Хуссар Ирыстон","Аҧсны - Абхазия","Լեռնային Ղարաբաղի Հանրապետությու (Nagorno-Karabakh Republic)"]
-                        - population: { max: 5000000 }
+                        any:
+                            - { population: { min: 50000, max: 84999 } }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 19
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.30,0.30,0.30]
+                                    size: 10px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 5px
+                                sprite: capital-m
+                                priority: 17
+                z8places-5:
+                    filter:
+                        all:
+                            - { population: { max: 50000 } }
+                        any:
+                            - country_capital: true
+                            - region_capital: true
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 19
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.30,0.30,0.30]
+                                    size: 10px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 5px
+                                sprite: capital-s
+                                priority: 17
+
+            populated-places-natural-earth-z8-backfill:
+                filter: { source: naturalearthdata.com, $zoom: [8], population: { max: 50000 } }
+                draw: { icons: { text: { font: { fill: global.text_fill } } } }
+                z8places-1-ne:
+                    filter: { min_zoom: [2,3] }
+                    draw:
+                        icons:
+                            size: 8px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-l-rev
+                            priority: 23
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 16px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 8px
+                                sprite: capital-l
+                                priority: 21
+
+                z8places-2-ne:
+                    filter: { min_zoom: [4,5,6] }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-m
+
+                z8places-3-ne:
+                    filter: { min_zoom: [6,7] }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 27
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 11px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-s
+                                priority: 25
+
+            populated-places-osm-z9:
+                filter:
+                    all:
+                        - source: openstreetmap.org
+                        - $zoom: [9]
+
+                z9places-1:
+                    filter:
+                        any:
+                            - { population: { min: 1000000 } }
+                    draw:
+                        text-blend-order:
+                            anchor: center
+                            visible: global.text_visible_populated_places
+                            priority: 6
+                            font:
+                                size: 17px
+#                                fill: global.text_fill
+#                                stroke: { color: global.text_stroke, width: 4 }
+
+                z9places-2a:
+                    filter:
+                        any:
+                            - { population: { min: 350000, max: 999999 } }
+                    draw:
+                        text-blend-order:
+                            anchor: center
+                            visible: global.text_visible_populated_places
+                            priority: 8
+                            font:
+                                size: 13px
+#                                fill: global.text_fill
+#                                stroke: { color: global.text_stroke, width: 4 }
+
+                z9places-2b:
+                    filter:
+                        any:
+                            - { population: { min: 150000, max: 350000 } }
+                    draw:
+                        icons:
+                            size: 6px
+                            sprite: townspot-m-rev
+                            priority: 11
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-m
+                                priority: 9
+
+                z9places-3:
+                    filter:
+                        any:
+                            - { population: { min: 85000, max: 149999 } }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 15
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.25,0.25,0.25]
+                                    size: 11px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-m
+                                priority: 13
+                                text:
+                                    font:
+                                        size: 15px
+
+                z9places-4:
+                    filter:
+                        any:
+                            - { population: { min: 50000, max: 84999 } }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 19
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.30,0.30,0.30]
+                                    size: 9px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-s
+                                priority: 17
+                z9places-5:
+                    filter:
+                        all:
+                            - { population: { max: 50000 } }
+                        any:
+                            - country_capital: true
+                            - region_capital: true
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 19
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.30,0.30,0.30]
+                                    size: 9px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-s
+                                priority: 17
+
+            populated-places-osm-z9-no-population:
+                filter:
+                    all:
+                        - source: openstreetmap.org
+                        - $zoom: [9]
+                        - kind: [city,town]
+                draw:
+                    icons:
+                        size: 5px
+                        visible: global.icon_visible_populated_places
+                        sprite: townspot-s-rev
+                        priority: 21
+                        text:
+                            visible: global.text_visible_populated_places
+                            font:
+                                size: 10px
+
+            populated-places-natural-earth-z9-backfill:
+                filter: { name: true, source: naturalearthdata.com, $zoom: [9], population: { max: 50000 } }
+                draw: { icons: { text: { font: { fill: global.text_fill } } } }
+                z9places-1-ne:
+                    filter: { scalerank: [0,1] }
                     draw:
-                        text-blend-order:
-                            visible: false
-            country-z6:
-                filter:
-                    $zoom: [6]
-                draw:
-                    text-blend-order:
-                        priority: 8
-                        font:
-                            size: 16px
-                small-ones-z6:
-                    filter:
-                        # South Ossetia and Abkhazia aren't countries (they are disputed areas)
-                        - name: [Luxembourg,Liechtenstein,San Marino,Civitatis Vaticanæ,België - Belgique - Belgien,"Хуссар Ирыстон - Южная Осетия","Хуссар Ирыстон","Аҧсны - Абхазия","Լեռնային Ղարաբաղի Հանրապետությու (Nagorno-Karabakh Republic)"]
-                        - population: { max: 5000000 }
+                        icons:
+                            size: 8px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-l-rev
+                            priority: 25
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 16px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-l
+                                priority: 23
+
+                z9places-2-ne:
+                    filter: { scalerank: [2,3,4,5] }
                     draw:
-                        text-blend-order:
-                            visible: false
-            country-z7:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 29
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-m
+                                priority: 28
+
+                z9places-3-ne:
+                    filter: { scalerank: [6,7,8,9] }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 33
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 11px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-m
+                                priority: 31
+
+            populated-places-osm-z10:
                 filter:
-                    $zoom: { min: 7, max: 9 }
-                draw:
-                    text-blend-order:
-                        font:
-                            size: [[7,18px],[9,24px]]
-                small-ones-z7:
+                    all:
+                        - source: openstreetmap.org
+                        - $zoom: [10]
+
+                z10places-1:
                     filter:
-                        $zoom: [7]
-                        # South Ossetia and Abkhazia aren't countries (they are disputed areas)
-                        name: [Liechtenstein,San Marino,Civitatis Vaticanæ,"Хуссар Ирыстон - Южная Осетия","Хуссар Ирыстон","Аҧсны - Абхазия","Լեռնային Ղարաբաղի Հանրապետությու (Nagorno-Karabakh Republic)"]
+                        any:
+                            - { population: { min: 1000000 } }
                     draw:
                         text-blend-order:
-                            visible: false
-                small-pop:
+                            anchor: center
+                            visible: global.text_visible_populated_places
+                            # TODO: Why is this here?
+                            priority: 5
+                            font:
+                                size: 17px
+
+                z10places-2a:
                     filter:
-                        - population: { max: 5000000 }
+                        any:
+                            - { population: { min: 350000, max: 1000000 } }
                     draw:
                         text-blend-order:
-                            priority: 30
+                            anchor: center
+                            visible: global.text_visible_populated_places
+                            # TODO: Why is this here?
+                            priority: 6
                             font:
-                                size: 12px
+                                size: 13px
+#                                fill: global.text_fill
+#                                stroke: { color: global.text_stroke, width: 4 }
 
-        region:
-            filter:
-                kind: region
-                $zoom: { min: 4, max: 9 }
-            draw:
-                text-blend-order:
-                    priority: 14
-                    visible: false
-                    text_source: global.ux_language_text_source_short
-                    font:
-                        size: 10px
-                        weight: 300
-                        fill: [0.3,0.3,0.3]
-            region-z4:
+                z10places-2b:
+                    filter:
+                        any:
+                            - { population: { min: 150000, max: 350000 } }
+                    draw:
+                        icons:
+                            size: 6px
+                            sprite: townspot-m-rev
+                            priority: 7
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+
+                z10places-3:
+                    filter:
+                        any:
+                            - { population: { min: 50000, max: 149999 } }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 11
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.25,0.25,0.25]
+                                    size: 11px
+
+                z10places-4:
+                    filter:
+                        any:
+                            - { population: { min: 20000, max: 49999 } }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 13
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.35,0.35,0.35]
+                                    size: 9px
+
+            populated-places-osm-z10-no-population:
                 filter:
-                    $zoom: [4]
-                    not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
+                    all:
+                        - source: openstreetmap.org
+                        - $zoom: [10]
+                        - kind: [city,town]
                 draw:
-                    text-blend-order:
-                        visible: global.text_visible_admin
-            region-z5:
+                    icons:
+                        size: 5px
+                        visible: global.icon_visible_populated_places
+                        sprite: townspot-s-rev
+                        priority: 15
+                        text:
+                            visible: global.text_visible_populated_places
+                            font:
+                                size: 10px
+
+            populated-places-natural-earth-z10-backfill:
+                filter: { name: true, source: naturalearthdata.com, $zoom: [10], population: { max: 20000 } }
+                draw: { icons: { text: { font: { fill: global.text_fill } } } }
+                z10places-1-ne:
+                    filter: { scalerank: [0,1] }
+                    draw:
+                        icons:
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 16px
+
+                z10places-2-ne:
+                    filter: { scalerank: [2,3,4,5] }
+                    draw:
+                        icons:
+                            size: 6px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-m-rev
+                            priority: 21
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                sprite: capital-m
+                                priority: 20
+
+                z10places-3-ne:
+                    filter: { scalerank: [6,7,8,9,10] }
+                    draw:
+                        icons:
+                            size: 5px
+                            visible: global.icon_visible_populated_places
+                            sprite: townspot-s-rev
+                            priority: 25
+                            text:
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 12px
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            icons:
+                                size: 7px
+                                sprite: capital-m
+                                priority: 23
+
+
+            populated-places-osm-z11:
                 filter:
-                    $zoom: [5]
-                    not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
-                draw:
-                    text-blend-order:
-                        visible: global.text_visible_admin
-                        font:
-                            size: 13px
-            region-z6:
+                    all:
+                        - source: openstreetmap.org
+                        - $zoom: [11]
+                        - population: true
+                no-townspots:
+                    filter: { kind_detail: [city,town] }
+
+                    z11places-1:
+                        filter:
+                            any:
+                                - { population: { min: 1000000 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                visible: global.text_visible_populated_places
+                                priority: 5
+                                font:
+                                    size: 18px
+    #                                fill: global.text_fill
+    #                                stroke: { color: global.text_stroke, width: 4 }
+
+                    z11places-2:
+                        filter:
+                            any:
+                                - { population: { min: 50000, max: 999999 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                visible: global.text_visible_populated_places
+                                priority: 6
+                                font:
+                                    size: 14px
+    #                                fill: global.text_fill
+    #                                stroke: { color: global.text_stroke, width: 4 }
+
+                    z11places-3:
+                        filter:
+                            any:
+                            - { population: { min: 5000, max: 49999 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                visible: global.text_visible_populated_places
+                                priority: 7
+                                font:
+                                    size: 12px
+    #                                fill: global.text_fill
+    #                                stroke: { color: global.text_stroke, width: 4 }
+
+                some-townspots:
+                    filter: { not: { kind_detail: [city,town] } }
+
+                    z11places-1:
+                        filter:
+                            any:
+                                - { population: { min: 1000000 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                visible: global.text_visible_populated_places
+                                # TODO: Why is this here?
+                                priority: 5
+                                font:
+                                    size: 17px
+
+                    z11places-2a:
+                        filter:
+                            any:
+                                - { population: { min: 350000, max: 1000000 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                visible: global.text_visible_populated_places
+                                # TODO: Why is this here?
+                                priority: 6
+                                font:
+                                    size: 13px
+    #                                fill: global.text_fill
+    #                                stroke: { color: global.text_stroke, width: 4 }
+
+                    z11places-2b:
+                        filter:
+                            any:
+                                - { population: { min: 150000, max: 350000 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                priority: 7
+                                visible: global.text_visible_populated_places
+                                font:
+                                    size: 13px
+
+                    z11places-3:
+                        filter:
+                            any:
+                                - { population: { min: 50000, max: 149999 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                size: 6px
+                                priority: 11
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.25,0.25,0.25]
+                                    size: 11px
+
+                    z11places-4:
+                        filter:
+                            any:
+                                - { population: { min: 20000, max: 49999 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                size: 5px
+                                priority: 13
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.35,0.35,0.35]
+                                    size: 9px
+
+                    z11places-6:
+                        filter:
+                            any:
+                                - { population: { max: 20000 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                size: 5px
+                                priority: 14
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.35,0.35,0.35]
+                                    size: 8px
+
+            populated-places-osm-z11-no-population:
                 filter:
-                    $zoom: [6]
-                    not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
+                    all:
+                        - source: openstreetmap.org
+                        - $zoom: [11]
+                        - population: false
                 draw:
                     text-blend-order:
-                        visible: global.text_visible_admin
+                        anchor: center
+                        visible: global.text_visible_populated_places
+                        priority: 8
                         font:
-                            size: 15px
-                            fill: [0.4,0.4,0.4]
-            region-z7-z8:
-                filter: { $zoom: [7,8] }
+                            size: 11px
+                            #fill: global.text_fill
+#                            stroke: { color: global.text_stroke, width: 4 }
+                village:
+                    filter: { kind_detail: [village] }
+                    draw:
+                        text-blend-order:
+                            font:
+                                #fill: green
+                                size: 9px
+
+            populated-places-natural-earth-z11-backfill:
+                filter: { source: naturalearthdata.com, $zoom: [11], population: { max: 5000 } }
                 draw:
                     text-blend-order:
-                        visible: global.text_visible_admin
-                        text_source: global.ux_language_text_source_short_proxy_name
+                        anchor: center
                         font:
-                            size: [[7,15px],[8,16px]]
-                            fill: [0.5,0.5,0.5]
-                            transform: uppercase
-                pesky-z7:
-                    filter:
-                        $zoom: [7]
-                        name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen]
+                            fill: global.text_fill
+                z11places-1-ne:
+                    filter: { min_zoom: [2,3] }
                     draw:
                         text-blend-order:
-                            visible: false
-                abbrev-small-ones-z7:
-                    filter:
-                        $zoom: [7]
-                        name: [Delaware,New Jersey,Connecticut,Rhode Island,Massachusetts,New Hampshire,Vermont]
+                            visible: global.text_visible_populated_places
+                            priority: 10
+                            font:
+                                size: 16px
+                                #stroke: { color: global.text_stroke, width: 4 }
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            text-blend-order:
+                                priority: 9
+                                font:
+                                    size: 16px
+                                    #stroke: { color: global.text_stroke, width: 4 }
+
+                z11places-2-ne:
+                    filter: { min_zoom: [4,5,6] }
                     draw:
                         text-blend-order:
-                            text_source: global.ux_language_text_source_abbreviation
-                            font: { transform: uppercase }
-                region-z8:
-                    filter:
-                        $zoom: [8]
+                            visible: global.text_visible_populated_places
+                            priority: 13
+                            font:
+                                size: 13px
+                                #stroke: { color: global.text_stroke, width: 4 }
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            text-blend-order:
+                                priority: 11
+                                font:
+                                    size: 16px
+                                    #stroke: { color: global.text_stroke, width: 4 }
+                    region_capital:
+                        filter: { region_capital: true }
+                        draw:
+                            text-blend-order:
+                                priority: 12
+                                font:
+                                    size: 14px
+                                    #stroke: { color: global.text_stroke, width: 4 }
+
+                z11places-3-ne:
+                    filter: { min_zoom: [6,7,8,9,10] }
+                    draw:
+                        text-blend-order:
+                            visible: global.text_visible_populated_places
+                            priority: 15
+                            font:
+                                size: 11px
+                                #stroke: { color: global.text_stroke, width: 4 }
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            text-blend-order:
+                                priority: 14
+                                font:
+                                    size: 14px
+                                    #stroke: { color: global.text_stroke, width: 4 }
+
+#            populated-places-osm-z12-debug:
+#                filter:
+#                    all:
+#                        - source: openstreetmap.org
+#                        - population: true
+#                        - kind_detail: [hamlet]
+#                        - $zoom: [12]
+#                draw:
+#                    icons:
+#                        size: 6px
+#                        sprite: townspot-m-rev
+#                        priority: 7
+#                        text:
+#                            visible: global.text_visible_populated_places
+#                            font:
+#                                size: 10px
+#                                fill: red
+#                village:
+#                    filter: { kind_detail: [village] }
+#                    draw:
+#                        icons:
+#                            text:
+#                                font:
+#                                    fill: green
+
+            populated-places-osm-z12:
+                filter:
+                    all:
+                        - $zoom: [12]
+                        - source: openstreetmap.org
+                        - population: true
+                no-townspots:
+                    filter: { kind_detail: [city,town] }
+
                     draw:
                         text-blend-order:
-                            text_source: global.ux_language_text_source
-                    no-pop:
+                            anchor: center
+
+                    z12places-1:
+                        filter:
+                            any:
+                                - { population: { min: 1000000 } }
+
+                        draw:
+                            text-blend-order:
+                                visible: global.text_visible_populated_places
+                                priority: 5
+                                font:
+                                    size: 18px
+                                    #fill: global.text_fill
+   #                                 stroke: { color: global.text_stroke, width: 4 }
+
+                    z12places-2:
+                        filter:
+                            any:
+                                - { population: { min: 50000, max: 999999 } }
+                        draw:
+                            text-blend-order:
+                                visible: global.text_visible_populated_places
+                                priority: 6
+                                font:
+                                    size: 14px
+                                    #fill: global.text_fill
+   #                                 stroke: { color: global.text_stroke, width: 4 }
+
+                    z12places-3:
+                        filter:
+                            any:
+                            - { population: { min: 5000, max: 49999 } }
+                        draw:
+                            text-blend-order:
+                                visible: global.text_visible_populated_places
+                                priority: 7
+                                font:
+                                    size: 11px
+                                    #fill: global.text_fill
+   #                                 stroke: { color: global.text_stroke, width: 4 }
+
+                    z12places-4:
+                        filter:
+                            any:
+                            - { population: { max: 5000 } }
+                        draw:
+                            text-blend-order:
+                                visible: global.text_visible_populated_places
+                                priority: 8
+                                font:
+                                    size: 10px
+                                    #fill: global.text_fill
+   #                                 stroke: { color: global.text_stroke, width: 4 }
+
+                some-townspots:
+                    filter: { not: { kind_detail: [city,town] } }
+
+                    z12places-1:
+                        filter:
+                            any:
+                                - { population: { min: 1000000 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                visible: global.text_visible_populated_places
+                                # TODO: Why is this here?
+                                priority: 5
+                                font:
+                                    size: 17px
+
+                    z12places-2a:
+                        filter:
+                            any:
+                                - { population: { min: 350000, max: 1000000 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                visible: global.text_visible_populated_places
+                                # TODO: Why is this here?
+                                priority: 6
+                                font:
+                                    size: 13px
+    #                                 fill: global.text_fill
+    #                                 stroke: { color: global.text_stroke, width: 4 }
+
+                    z12places-2b:
                         filter:
                             any:
-                                - population: false
-                                - population: { max: 1000000 }
+                                - { population: { min: 150000, max: 350000 } }
                         draw:
                             text-blend-order:
+                                anchor: center
+                                size: 6px
+                                priority: 7
+                                visible: global.text_visible_populated_places
                                 font:
                                     size: 13px
 
-        populated-places:
-            filter:
-                kind: locality
-            draw:
-                icons:
-                    visible: global.icon_visible_populated_places
-                    size: [[10,4px],[11,0px]]
-                    sprite: townspot-xs-rev
-                    buffer: 8px
-                    priority: 30
-                    # debug testing
-                    #collide: false
-                    text:
-                        visible: global.text_visible_populated_places
-                        font:
-                            size: [[5,9px],[8,10px],[12,11px]]
-                text-blend-order:
-                    visible: global.text_visible_populated_places
-                    buffer: 8px
-                    font:
-                        size: [[5,9px],[8,10px],[12,11px]]
-
-            #
-            # NOTE: you'd think no-townspot would be the way to go, but icons with size 0px seems to have a bug to also hide the text :(
-            #
-            # no-townspot:
-            #     filter: { $zoom: { min: 11 } }
-            #     draw:
-            #         icons:
-            #             size: 0px
-            #             text:
-            #                 anchor: center
-            #
-            # NOTE: So instead we play a shell game with symbolizers per zoom
-            #
-            _icons_later:
-                filter: { $zoom: { min: 11 } }
-                draw:
-                    icons:
-                        visible: false
-                    text-blend-order:
-                        visible: global.text_visible_populated_places
-            _text_early:
-                filter: { $zoom: { max: 11 } }
-                draw:
-                    text-blend-order:
-                        visible: false
-            # END HACK
-
-            z8-50k-below:
-                filter: { $zoom: [8,9], population: { min: 10000, max: 50000 } }
-                draw:
-                    icons:
-                        buffer: 25px
-                        #color: red
-                        #visible: false
-            z9-10k-below:
-                filter: { $zoom: [8,9], population: { max: 10000 } }
-                draw:
-                    icons:
-                        buffer: 18px
-                        #color: blue
-                        #visible: false
-            z9-no-population:
-                filter: { $zoom: [8,9], population: false }
-                draw:
-                    icons:
-                        buffer: 10px
-                        #color: yellow
-                        #visible: false
+                    z12places-3:
+                        filter:
+                            any:
+                                - { population: { min: 50000, max: 149999 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                size: 6px
+                                priority: 11
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.25,0.25,0.25]
+                                    size: 12px
 
-            sorry-denver:
-                filter:
-                    $zoom: [3]
-                    name: [Denver]
-                draw:
-                    icons:
-                        visible: false
+                    z12places-4:
+                        filter:
+                            any:
+                                - { population: { min: 20000, max: 49999 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                size: 5px
+                                priority: 13
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.35,0.35,0.35]
+                                    size: 11px
 
-            # HACK
-            # NOTE: These should use icon: buffer instead of going visible: false, but there are problems using icon here :(
-            # This fixes Paris area, but causes problems for small places in the USA eg Table Bluff near Eureka, California.
-            funky-village:
-                filter: { $zoom: [11], population: { max: 1000 }, kind_detail: [village] }
-                draw:
-                    text-blend-order:
-                        visible: false
-            funky-isolated_dwelling:
-                filter: { $zoom: [13], kind_detail: [isolated_dwelling] }
-                draw:
-                    text-blend-order:
-                        visible: false
-            hamlet:
-                filter: { $zoom: [13], kind_detail: hamlet }
-                draw:
-                    text-blend-order:
-                        visible: false
-            # END HACK
+                    z12places-6:
+                        filter:
+                            any:
+                                - { population: { max: 20000 } }
+                        draw:
+                            text-blend-order:
+                                anchor: center
+                                size: 5px
+                                priority: 14
+                                visible: global.text_visible_populated_places
+                                font:
+                                    fill: [0.35,0.35,0.35]
+                                    size: 10px
 
-            # someone in London and Salt Lake City thought neighbourhoods should be tagged place: locality
-            # They were wrong
-            funky-fake-neighbourhoods:
-                filter: { $zoom: { min: 13 }, kind_detail: [locality] }
-                draw:
-                    text-blend-order:
-                        visible: false
+                    hamlet:
+                        filter: { kind_detail: [hamlet] }
+                        draw:
+                            text-blend-order:
+                                #visible: false
+                                font:
+                                    #fill: magenta
+                                    size: 9px
 
-            population-10m-up:
+            populated-places-osm-z12-no-population:
                 filter:
-                    population: { min: 10000000 }
+                    all:
+                        - $zoom: [12]
+                        - source: openstreetmap.org
+                        - population: false
+                        #- kind_detail: [city,town,village,hamlet]
                 draw:
-                    icons:
-                        size: [[4,5px],[8,6px],[9,0px]]
-                        sprite: townspot-m-rev
-                        priority: 6
-                        text:
-                            font:
-                                size: [[2,11px],[6,15px],[8,16px],[10,18px],[12,18px],[13,0px]]
                     text-blend-order:
-                        priority: 6
+                        anchor: center
+                        visible: global.text_visible_populated_places
+                        priority: 9
                         font:
-                            size: [[2,11px],[6,15px],[8,16px],[10,18px],[12,18px],[13,0px]]
-                capital:
-                    # we only want townspots to show as capital dots starting at zoom 5
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                            size: 11px
+                            #fill: cyan
+                            #fill: global.text_fill
+                            #stroke: { color: global.text_stroke, width: 4 }
+                hamlet:
+                    filter: { kind_detail: [hamlet] }
                     draw:
-                        icons:
-                            size: [[10,8px],[11,0px]]
-                            sprite: capital-l
-                            priority: 5
                         text-blend-order:
-                            priority: 5
-            population-5m-10m:
-                filter:
-                    population: { min: 5000000, max: 10000000 }
-                draw:
-                    icons:
-                        size: [[4,5px],[8,6px],[9,0px]]
-                        sprite: townspot-m-rev
-                        priority: 7
-                        text:
+                            visible: false
                             font:
-                                size: [[4,10px],[6,13px],[8,16px],[10,18px],[12,18px],[13,0px]]
-                    text-blend-order:
-                        priority: 7
-                        font:
-                            size: [[4,10px],[6,13px],[8,16px],[10,18px],[12,18px],[13,0px]]
-                capital:
-                    # we only want townspots to show as capital dots starting at zoom 5
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                                #fill: magenta
+                                size: 9px
+                village:
+                    filter: { kind_detail: [village] }
                     draw:
-                        icons:
-                            size: [[10,8px],[11,0px]]
-                            sprite: capital-l
-                            priority: 6
                         text-blend-order:
-                            priority: 6
-            population-1m-5m:
-                filter:
-                    population: { min: 1000000, max: 5000000 }
-                draw:
-                    icons:
-                        size: [[4,5px],[8,6px],[9,0px]]
-                        sprite: townspot-m-rev
-                        priority: 9
-                        text:
                             font:
-                                size: [[4,10px],[6,13px],[8,16px],[10,18px],[12,18px],[13,0px]]
+                                #fill: green
+                                size: 9px
+
+            populated-places-natural-earth-z12-backfill:
+                filter: { source: naturalearthdata.com, $zoom: [12], population: { max: 5000 } }
+                draw:
                     text-blend-order:
-                        priority: 9
+                        anchor: center
+                        priority: 10
                         font:
-                            size: [[4,10px],[6,13px],[8,16px],[10,18px],[12,18px],[13,0px]]
-                capital:
-                    # we only want townspots to show as capital dots starting at zoom 5
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                            fill: global.text_fill
+
+                z12places-1-ne:
+                    filter: { scalerank: [0,1] }
                     draw:
-                        icons:
-                            size: [[10,8px],[11,0px]]
-                            sprite: capital-l
-                            priority: 8
                         text-blend-order:
-                            priority: 8
-            population-500k-1m:
-                filter:
-                    population: { min: 500000, max: 1000000 }
-                draw:
-                    icons:
-                        size: [[8,6px],[9,0px]]
-                        sprite: townspot-m-rev
-                        priority: 11
-                        text:
+                            visible: global.text_visible_populated_places
+                            priority: 12
                             font:
-                                size: [[5,10px],[8,14px],[10,14px],[12,16px],[13,0px]]
-                    text-blend-order:
-                        priority: 11
-                        font:
-                            size: [[5,10px],[8,14px],[10,14px],[12,16px],[13,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                                size: 16px
+                                #stroke: { color: global.text_stroke, width: 4 }
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            text-blend-order:
+                                priority: 11
+                                font:
+                                    size: 16px
+                                    #stroke: { color: global.text_stroke, width: 4 }
+
+                z12places-2-ne:
+                    filter: { scalerank: [2,3,4,5] }
                     draw:
-                        icons:
-                            size: [[10,6px],[11,0px]]
-                            sprite: capital-m
-                            priority: 10
                         text-blend-order:
-                            priority: 10
-            population-200k-500k:
-                filter:
-                    population: { min: 200000, max: 500000 }
-                draw:
-                    icons:
-                        size: [[8,6px],[9,6px],[10,6px],[11,0px]]
-                        sprite: townspot-m-rev
-                        priority: 13
-                        text:
+                            visible: global.text_visible_populated_places
+                            priority: 14
                             font:
-                                size: [[6,10px],[8,12px],[10,14px],[12,16px],[13,0px]]
-                    text-blend-order:
-                        priority: 13
-                        font:
-                            size: [[6,10px],[8,12px],[10,14px],[12,16px],[13,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                                size: 13px
+                                #stroke: { color: global.text_stroke, width: 4 }
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            text-blend-order:
+                                priority: 13
+                                font:
+                                    size: 16px
+                                    #stroke: { color: global.text_stroke, width: 4 }
+
+                z12places-3-ne:
+                    filter: { scalerank: [6,7,8,9,10,11,12] }
                     draw:
-                        icons:
-                            size: [[10,6px],[11,0px]]
-                            sprite: capital-m
-                            priority: 12
                         text-blend-order:
-                            priority: 12
-            population-100k-200k:
+                            visible: global.text_visible_populated_places
+                            priority: 16
+                            font:
+                                size: 11px
+                                #stroke: { color: global.text_stroke, width: 4 }
+                    capital:
+                        filter: { country_capital: true }
+                        draw:
+                            text-blend-order:
+                                priority: 15
+                                font:
+                                    size: 14px
+                                    #stroke: { color: global.text_stroke, width: 4 }
+
+            populated-places-osm-z13-z14:
                 filter:
-                    population: { min: 100000, max: 200000 }
+                    all:
+                        - source: openstreetmap.org
+                        - population: true
+                        - $zoom: [13,14]
                 draw:
-                    icons:
-                        size: [[8,6px],[9,6px],[10,6px],[11,0px]]
-                        sprite: townspot-m-rev
-                        priority: 15
-                        text:
-                            font:
-                                size: [[6,10px],[8,12px],[10,12px],[12,14px],[14,14px],[15,0px]]
                     text-blend-order:
-                        priority: 15
+                        anchor: center
+                        visible: global.text_visible_populated_places
                         font:
-                            size: [[6,10px],[8,12px],[10,12px],[12,14px],[14,14px],[15,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                            weight: 600
+                            fill: global.text_fill
+                z14:
+                    filter:
+                        $zoom: [14]
                     draw:
-                        icons:
-                            size: [[10,6px],[11,0px]]
-                            sprite: capital-m
-                            priority: 14
                         text-blend-order:
-                            priority: 14
-            population-50k-100k:
-                filter:
-                    population: { min: 50000, max: 100000 }
-                draw:
-                    icons:
-                        size: [[8,5px],[9,5px],[10,6px],[11,0px]]
-                        sprite: townspot-s-rev
-                        priority: 17
-                        text:
                             font:
-                                fill: [0.30,0.30,0.30]
-                                size: [[6,10px],[8,11px],[10,12px],[12,14px],[14,14px],[15,0px]]
-                    text-blend-order:
-                        priority: 17
-                        font:
-                            fill: [0.30,0.30,0.30]
-                            size: [[6,10px],[8,11px],[10,12px],[12,14px],[14,14px],[15,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                                weight: 600
+
+                z13places-1:
+                    filter:
+                        any:
+                            - { population: { min: 200000 } }
                     draw:
-                        icons:
-                            size: [[10,5px],[11,0px]]
-                            sprite: capital-m
-                            priority: 16
                         text-blend-order:
-                            priority: 16
-            population-20k-50k:
-                filter:
-                    population: { min: 20000, max: 50000 }
-                draw:
-                    icons:
-                        size: [[8,5px],[9,5px],[10,5px],[11,0px]]
-                        sprite: townspot-s-rev
-                        priority: 19
-                        text:
-                            font:
-                                fill: [0.30,0.30,0.30]
-                                size: [[9,11px],[12,12px],[14,12px],[15,0px]]
-                    text-blend-order:
-                        priority: 19
-                        font:
-                            fill: [0.30,0.30,0.30]
-                            size: [[9,11px],[12,12px],[14,12px],[15,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                            visible: false
+
+                z13places-2:
+                    filter:
+                        any:
+                            - { population: { min: 50000, max: 199999 } }
                     draw:
-                        icons:
-                            size: [[10,5px],[11,0px]]
-                            sprite: capital-s
-                            priority: 18
                         text-blend-order:
-                            priority: 18
-            population-10k-20k:
-                filter:
-                    population: { min: 10000, max: 20000 }
-                draw:
-                    icons:
-                        size: [[8,4px],[9,4px],[10,4px],[11,0px]]
-                        sprite: townspot-xs-rev
-                        priority: 21
-                        text:
+                            visible: global.text_visible_populated_places
+                            priority: 5
                             font:
-                                fill: [0.35,0.35,0.35]
-                                size: [[9,11px],[12,12px],[14,12px],[15,0px]]
-                    text-blend-order:
-                        priority: 21
-                        font:
-                            fill: [0.35,0.35,0.35]
-                            size: [[9,11px],[12,12px],[14,12px],[15,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                                size: 14px
+                                #stroke: { color: global.text_stroke, width: 4 }
+
+                z13places-3:
+                    filter:
+                        any:
+                        - { population: { min: 5000, max: 49999 } }
                     draw:
-                        icons:
-                            size: [[10,5px],[11,0px]]
-                            sprite: capital-s
-                            priority: 20
                         text-blend-order:
-                            priority: 20
-            population-5k-10k:
-                filter:
-                    population: { min: 5000, max: 10000 }
-                draw:
-                    icons:
-                        size: [[8,4px],[9,4px],[10,4px],[11,0px]]
-                        sprite: townspot-xs-rev
-                        priority: 23
-                        text:
+                            visible: global.text_visible_populated_places
+                            priority: 6
                             font:
-                                fill: [0.35,0.35,0.35]
-                                size: [[9,10px],[12,12px],[13,12px],[14,12px],[15,0px]]
-                    text-blend-order:
-                        priority: 23
-                        font:
-                            fill: [0.35,0.35,0.35]
-                            size: [[9,10px],[12,12px],[13,12px],[14,12px],[15,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                                size: 12px
+                                #stroke: { color: global.text_stroke, width: 4 }
+
+                z13places-4:
+                    filter:
+                        - population: { max: 5000 }
                     draw:
-                        icons:
-                            size: [[10,5px],[11,0px]]
-                            sprite: capital-s
-                            priority: 22
                         text-blend-order:
-                            priority: 22
-            population-2k-5k:
+                            font:
+                                size: 12px
+                                #stroke: { color: global.text_stroke, width: 4 }
+
+            populated-places-osm-z13-z14-no-population:
                 filter:
-                    population: { min: 2000, max: 5000 }
+                    all:
+                        - source: openstreetmap.org
+                        - population: false
+                        - $zoom: [13, 14]
+                        #- kind_detail: [city,town]
                 draw:
-                    icons:
-                        size: [[8,4px],[9,4px],[10,4px],[11,0px]]
-                        sprite: townspot-xs-rev
-                        priority: 25
-                        text:
-                            font:
-                                fill: [0.35,0.35,0.35]
-                                size: [[9,10px],[12,10px],[13,12px],[14,12px],[15,0px]]
                     text-blend-order:
-                        priority: 25
+                        anchor: center
+                        visible: global.text_visible_populated_places
+                        priority: 7
                         font:
-                            fill: [0.35,0.35,0.35]
-                            size: [[9,10px],[12,10px],[13,12px],[14,12px],[15,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
-                    draw:
-                        icons:
-                            size: [[10,5px],[11,0px]]
-                            sprite: capital-s
-                            priority: 24
-                        text-blend-order:
-                            priority: 24
-            population-1k-2k:
-                filter:
-                    population: { min: 1000, max: 2000 }
+                            size: 11px
+                            #fill: orange
+                            #stroke: { color: global.text_stroke, width: 4 }
+
+#                city_town:
+#                    filter:
+#                        all:
+#                            - kind_detail: [city,town]
+#                    draw:
+#                        text-blend-order:
+#                            font:
+#                                fill: yellow
+#
+#                hamlet:
+#                    filter: { kind_detail: [hamlet] }
+#                    draw:
+#                        icons:
+#                            text:
+#                                font:
+#                                    fill: brown
+#
+#                village:
+#                    filter: { kind_detail: [village] }
+#                    draw:
+#                        icons:
+#                            text:
+#                                font:
+#                                    fill: green
+#
+#                locality:
+#                    filter: { kind_detail: [locality] }
+#                    draw:
+#                        icons:
+#                            text:
+#                                font:
+#                                    fill: purple
+#
+#                isolated_dwelling_farm:
+#                    filter: { kind_detail: [isolated_dwelling,farm] }
+#                    draw:
+#                        icons:
+#                            text:
+#                                font:
+#                                    fill: pink
+
+
+            populated-places-natural-earth-z13-z14-backfill:
+                filter: { source: naturalearthdata.com, $zoom: [13,14], population: { max: 5000 } }
                 draw:
-                    icons:
-                        size: [[8,4px],[9,4px],[10,4px],[11,0px]]
-                        sprite: townspot-xs-rev
-                        priority: 27
-                        text:
-                            font:
-                                fill: [0.35,0.35,0.35]
-                                size: [[9,10px],[12,10px],[14,11px],[15,0px]]
                     text-blend-order:
-                        priority: 27
+                        anchor: center
                         font:
-                            fill: [0.35,0.35,0.35]
-                            size: [[9,10px],[12,10px],[14,11px],[15,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                            fill: global.text_fill
+                            weight: 400
+
+                z13places-1-ne:
+                    filter: { min_zoom: [2,3] }
                     draw:
-                        icons:
-                            size: [[10,5px],[11,0px]]
-                            sprite: capital-s
-                            priority: 26
                         text-blend-order:
-                            priority: 26
-            population-200-1k:
-                filter:
-                    population: { min: 200, max: 1000 }
-                draw:
-                    icons:
-                        size: [[8,4px],[9,4px],[10,4px],[11,0px]]
-                        sprite: townspot-xs-rev
-                        priority: 28
-                        text:
+                            priority: 8
+                            interactive: false
+                            visible: false
+
+                z13places-2-ne:
+                    filter: { min_zoom: [4,5,6] }
+                    draw:
+                        text-blend-order:
+                            priority: 9
+                            visible: global.text_visible_populated_places
                             font:
-                                fill: [0.35,0.35,0.35]
-                                size: [[9,10px],[12,10px],[14,11px],[15,0px]]
-                    text-blend-order:
-                        priority: 28
-                        font:
-                            fill: [0.35,0.35,0.35]
-                            size: [[9,10px],[12,10px],[14,11px],[15,0px]]
-                capital:
-                    filter: { country_capital: true, $zoom: { min: 5 } }
+                                size: 13px
+                                #stroke: { color: global.text_stroke, width: 4 }
+
+                z13places-3-ne:
+                    filter: { min_zoom: [7,8,9,10] }
                     draw:
-                        icons:
-                            size: [[10,5px],[11,0px]]
-                            sprite: capital-s
-                            priority: 27
                         text-blend-order:
-                            priority: 27
+                            visible: global.text_visible_populated_places
+                            priority: 10
+                            font:
+                                size: 12px
+                                #stroke: { color: global.text_stroke, width: 4 }
+
+        neighborhoods:
+            filter: { kind: [macrohood, neighbourhood, borough] }
 
-        #
-        #neighborhoods (excluding microhoods, eg the Tendernob)
-        #
-        neighbourhood:
-            filter:
-                kind:
-                    - macrohood
-                    - neighbourhood
-                    - borough
-                $zoom: { min: 10 }
-                is_landuse_aoi: false
-            draw:
-                text-blend-order:
-                    # there are more labels than we want to show, so we hide them,
-                    # then selectively reveal in classes below (ultimately a data problem)
-                    visible: false
-                    priority: 29
-                    buffer: 8px
-                    text_wrap: 10
-                    max_lines: 2
-                    font:
-                        family: Varela
-                        fill: [0.225,0.561,0.415]
-                        transform: uppercase
             neighborhood-z11:
                 filter:
-                    $zoom: [11]
-                    min_zoom: [11]
-                    max_zoom: { min: 12 }
-                    #kind_tile_rank: { max: 6 }
+                    all:
+                        - $zoom: [11]
+                          all:
+                            - min_zoom: [11]
+                            - max_zoom: { min: 12 }
+                            - is_landuse_aoi: false
+                            #- kind_tile_rank: { max: 6 }
                 draw:
                     text-blend-order:
+                        priority: 18
+                        text_wrap: 10
                         visible: global.text_visible_neighbourhoods_e
                         font:
                             size: 9px
+                            weight: 400
+                            fill: global.text_fill
+                            transform: uppercase
                             stroke: { color: global.text_stroke, width: 4 }
             neighborhood-z12:
                 filter:
-                    $zoom: [12]
-                    min_zoom: [11,12]
-                    max_zoom: { min: 13 }
-                    #kind_tile_rank: { max: 8 }
+                    all:
+                        - $zoom: [12]
+                          all:
+                            - min_zoom: [11,12]
+                            - max_zoom: { min: 13 }
+                            - is_landuse_aoi: false
+                            #- kind_tile_rank: { max: 8 }
                 draw:
                     text-blend-order:
+                        priority: 18
+                        text_wrap: 10
                         visible: global.text_visible_neighbourhoods_e
                         font:
                             size: 10px
+                            weight: 400
+                            fill: [0.300,0.300,0.300]
+                            transform: uppercase
+                            # stroke: { color: global.text_stroke, width: 2 }
             neighborhood-z13:
                 filter:
-                    $zoom: [13]
-                    min_zoom: [11,12,13]
-                    max_zoom: { min: 14 }
-                    kind_tile_rank: { max: 8 }
+                    all:
+                        - $zoom: [13]
+                          all:
+                            - min_zoom: [11,12,13]
+                            - max_zoom: { min: 14 }
+                            - is_landuse_aoi: false
+                            - kind_tile_rank: { max: 8 }
                 draw:
                     text-blend-order:
+                        priority: 18
+                        text_wrap: 10
                         visible: global.text_visible_neighbourhoods_e
                         font:
                             size: 11px
+                            weight: 400
+                            fill: [0.35,0.35,0.35]
+                            transform: uppercase
+                            # stroke: { color: global.text_stroke, width: 2 }
             neighborhood-z14:
                 filter:
-                    $zoom: [14]
-                    min_zoom: [11,12,13,14]
-                    max_zoom: { min: 15 }
-                    kind_tile_rank: { max: 8 }
+                    all:
+                        - $zoom: [14]
+                          all:
+                            - min_zoom: [11,12,13,14]
+                            - max_zoom: { min: 15 }
+                            - is_landuse_aoi: false
+                            - kind_tile_rank: { max: 8 }
                 draw:
                     text-blend-order:
+                        priority: 18
                         text_wrap: 12
-                        max_lines: 3
                         visible: global.text_visible_neighbourhoods
                         font:
-                            size: 12px
+                            size: 13px
+                            weight: 400
+                            fill: [0.000,0.000,0.000,0.500]
+                            transform: uppercase
+                            # stroke: { color: global.text_stroke, width: 3 }
             neighborhood-z15:
                 filter:
-                    $zoom: [15]
-                    min_zoom: [11,12,13,14,15]
-                    max_zoom: { min: 16 }
-                    kind_tile_rank: { max: 8 }
+                    all:
+                        - $zoom: [15]
+                          all:
+                            - min_zoom: [11,12,13,14,15]
+                            - max_zoom: { min: 16 }
+                            - is_landuse_aoi: false
+                            - kind_tile_rank: { max: 8 }
                 draw:
                     text-blend-order:
+                        priority: 18
                         text_wrap: 12
-                        max_lines: 4
                         visible: global.text_visible_neighbourhoods
                         font:
-                            size: 14px
+                            size: 16px
+                            weight: 300
+                            fill: [0.000,0.000,0.000,0.480]
+                            transform: uppercase
+                            # stroke: { color: global.text_stroke, width: 3 }
                 z15-new:
                     filter:
                         all:
@@ -4671,613 +4843,1544 @@ layers:
                                 size: 13px
             neighborhood-z16:
                 filter:
-                    $zoom: [16]
-                    min_zoom: [11,12,13,14,15,16]
-                    max_zoom: { min: 17 }
-                    kind_tile_rank: { max: 8 }
+                    all:
+                        - $zoom: [16]
+                          all:
+                            - min_zoom: [11,12,13,14,15,16]
+                            - max_zoom: { min: 17 }
+                            - is_landuse_aoi: false
+                            - kind_tile_rank: { max: 8 }
                 draw:
                     text-blend-order:
-                        text_wrap: 12
-                        max_lines: 4
                         visible: global.text_visible_neighbourhoods
+                        priority: 18
                         font:
                             size: 17px
-    pois:
-        data: { source: mapzen, layer: pois }
-        #visible: global.label_visible_poi_landuse
+                            weight: 300
+                            fill: [0.000,0.000,0.000,0.400]
+                            transform: uppercase
+                            # stroke: { color: global.text_stroke, width: 3 }
+
+#    landuse_labels_debug:
+#        data: { source: mapzen, layer: [landuse] }
+#        #filter: { label_placement: true }
+#        draw:
+#            icons:
+#                size: [[13, 12px], [16, 16px], [18, 19px]]
+#                interactive: true
+#                repeat_group: abc
+#                text:
+#                    interactive: true
+#                    priority: 99
+#                    font:
+#                        family: global.text_font_family
+#                        weight: 800
+#                        fill: red #[0.20,0.20,0.20]
+#                        size: 12px
+#                        style: italic
+
+    pois_and_landuse_labels:
+        data: { source: mapzen, layer: [pois] }
+        visible: global.label_visible_poi_landuse
         filter:
             all:
                 - not: { kind: [building,address,farm,tree,apron,residential,commercial,industrial] }
+                - $geometry: point
                 # White list a few kinds to "always" show per the tile zoom inclusion, else test feature's min_zoom
                 #- function() { return feature.min_zoom <= $zoom }
                 - function() { if( feature.kind == 'restaurant' || feature.kind == 'landmark' || feature.kind == 'cafe' ) { return true } else { return feature.min_zoom <= $zoom } }
+                - any:
+                    - area: false
+                      all:
+                          - $zoom: { min: 12 }
+                    - area: true
+                      all:
+                          - kind: true
         draw:
             icons:
-                visible: global.icon_visible_poi_landuse
-                size: [[13, 14px], [16, 18px], [18, 19px]]
-                sprite: function() { return feature.kind; }
-                sprite_default: generic
-                interactive: global.sdk_interactive
-                priority: 65 #function() { return (feature.min_zoom && Math.floor(feature.min_zoom * 1000)) || 65; }
+                size: [[13, 12px], [16, 16px], [18, 19px]]
+                interactive: true
+                visible: false
+                priority: 65  #function() { return (feature.min_zoom && Math.floor(feature.min_zoom * 1000)) || 65; }
                 repeat_group: abc
-                buffer: 3px
                 text:
-                    visible: global.text_visible_poi_landuse
                     text_source: global.ux_language_text_source
-                    buffer: 3px
-                    text_wrap: 18
-                    max_lines: 3
+                    visible: false    # labels are enabled by each layer below
+                    move_into_tile: false # preserves text alignment w/icons in JS
+                    interactive: true
+                    priority: 66
                     font:
-                        family: Quicksand #global.text_font_family
-                        weight: normal
+                        family: global.text_font_family
+                        weight: 400
                         fill: [0.20,0.20,0.20]
-                        size: [[13,10px],[14,11px],[17,12px],[19,12px],[20,14px]]
-                        stroke: { color: global.text_stroke, width: [[12,2px],[16,4px]] }
-
-        # improve legibility at high zooms
+                        size: 10px
+                        stroke: { color: global.text_stroke, width: 1 }
+            text-blend-order:
+                text_source: global.ux_language_text_source
+                visible: false    # labels are enabled by each layer below
+                move_into_tile: false # preserves text alignment w/icons in JS
+                interactive: true
+                priority: 66
+                font:
+                    family: global.text_font_family
+                    weight: 400
+                    fill: [0.20,0.20,0.20]
+                    size: 10px
+                    stroke: { color: global.text_stroke, width: 1 }
+        poi_labels-z14:
+            filter: { $zoom: [14] }
+            draw: { icons: { text: { font: { size: 11px } } } }
+        poi_labels-z15:
+            filter: { $zoom: [15,16,17] }
+            draw: { icons: { text: { font: { size: 12px, stroke: { width: 2 } } } } }
         poi_labels-z18:
-            filter: { $zoom: { min: 18 } }
-            draw:
-                icons:
-                    text:
-                        # some pois have really long names
-                        max_lines: 5
-                        font:
-                            weight: 600
+            filter: { $zoom: [18,19] }
+            draw: { icons: { text: { font: { size: 12px, weight: 600, stroke: { width: 3 } } } } }
+        poi_labels-z20-up:
+            filter: { $zoom: { min: 20 } }
+            draw: { icons: { text: { font: { size: 14px, weight: 600, stroke: { width: 3 }  } } } }
 
-        # source icon sprite from something other than kind
-        sports-pitch:
-            filter: { kind: [grass, pitch] }
-            draw:
-                icons:
-                    sprite: function() { return feature.kind_detail; }
-                    # needs a better recreation icon, so just use generic (default) for now
-                    #sprite_default: sports
-        place_of_worship:
-            filter:
-                kind: [place_of_worship, wayside_chapel]
-            draw:
-                icons:
-                    sprite: function() { return feature.religion; }
-                    sprite_default: place_of_worship
-        # TODO: some or all of this may be unnecessary for the sprite, but is necessary for the early filter
-        building-icon:
-            filter:
-                kind: [apartments, auditorium, building, hangar, manor, recreation_center, retirement_home, terminal]
-            draw:
-                icons:
-                    sprite: building
-            early:
+        no-name:
+            filter: { name: false }
+            sports-pitch:
+                filter: { kind: [grass, pitch], $geometry: point, area: true, $zoom: { min: 17 } }
+                draw:
+                    icons:
+                        sprite: function() { return feature.kind_detail; }
+                        visible: global.icon_visible_poi_landuse_e
+                        priority: 69
+                baseball:
+                    filter: { kind_detail: baseball }
+                    draw: { icons: { sprite: baseball-field } }
+                basketball:
+                    filter: { kind_detail: basketball }
+                    draw: { icons: { sprite: basketball-court } }
+                football:
+                    filter: { kind_detail: football }
+                    draw: { icons: { sprite: football-stadium } }
+                hockey:
+                    filter: { kind_detail: hockey-field }
+                    draw: { icons: { sprite: hockey-field } }
+                soccer:
+                    filter: { kind_detail: soccer }
+                    draw: { icons: { sprite: soccer-field } }
+                tennis:
+                    filter: { sport: tennis }
+                    draw: { icons: { sprite: tennis } }
+            toilets:
+                filter: { kind: toilets, $zoom: { min: 18 }  }
+                draw: { icons: { sprite: toilets, visible: global.icon_visible_poi_landuse_e } }
+            playground:
+                filter: { kind: playground, $zoom: { min: 18 }  }
+                draw: { icons: { sprite: playground, visible: global.icon_visible_poi_landuse_e } }
+            picnic_site:
+                filter: { kind: picnic_site, $zoom: { min: 18 }  }
+                draw: { icons: { sprite: picnic-spot, visible: global.icon_visible_poi_landuse_e } }
+            information:
+                filter: { kind: information, $zoom: { min: 18 }  }
+                draw: { icons: { sprite: information, visible: global.icon_visible_poi_landuse_e } }
+            drinking-water:
+                filter: { kind: drinking_water, $zoom: { min: 18 }  }
+                draw: { icons: { sprite: drinking-water, visible: global.icon_visible_poi_landuse_e } }
+            traffic-signal:
+                filter: { kind: traffic_signals, $zoom: { min: 18 } }
+                draw:   { icons: { sprite: traffic-signal, visible: global.icon_visible_poi_landuse_e } }
+            bicycle-parking:
+                filter: { kind: [bicycle_parking], $zoom: { min: 19 } }
+                draw:   { icons: { sprite: bicycle-parking, visible: global.icon_visible_poi_landuse_e } }
+            car-parking:
+                filter: { kind: [parking], $zoom: { min: 17 } }
+                draw:   { icons: { sprite: parking, visible: global.icon_visible_poi_landuse_e } }
+        has-name:
+            filter: { name: true }
+            # match 1:1 correlations between data and sprite name
+            direct-match:
+                filter:
+                    all:
+                        - area: false
+                draw:
+                    icons:
+                        # sprite_source: kind
+                        sprite: function() { return feature.kind; }
+                        visible: global.icon_visible_poi_landuse
+
+            # add generic icon at high zoom, if direct match fails
+            generic-icons:
+                filter: { $zoom: { min: 18 }, area: false }
+                draw:
+                    icons:
+                        priority: 67
+                        sprite_default: generic
+                        visible: global.icon_visible_poi_landuse
+
+            # add generic icon at high zoom
+            default-label-names:
+                filter: { $zoom: { min: 13 }, area: false }
+                draw:
+                    icons:
+                        text:
+                            visible: global.text_visible_poi_landuse
+#                            priority: 68
+
+            landuse-labels-green-areas-national-park:
+                filter:
+                    all:
+                        - area: true
+                        - $geometry: point
+                        - kind: [national_park, battlefield, protected_area]
+                    #any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [4],  area: { min: 3000000000 } }
+#                        - { $zoom: [5],  area: { min: 3000000000 } }
+#                        - { $zoom: [6],  area: { min: 500000000 } }
+#                        - { $zoom: [7,8,9],  area: { min: 100000000 } }
+#                        - { $zoom: [10], area: { min: 50000000 } }
+#                        - { $zoom: [11], area: { min: 25000000 } }
+#                        - { $zoom: [12], area: { min: 5000000 } }
+#                        - { $zoom: [13], area: { min: 200000 } }
+#                        - { $zoom: [14], area: { min: 50000 } }
+#                        - { $zoom: { min: 15 } }
+                national-park:
+                    # yosemite national park, joshua tree national park
+                    filter: function() { return feature.name && ((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1 || feature.protect_class == '2' || feature.protect_class == '3' || feature.protect_class == '5'); }
+#                    visible: global.label_visible_landuse_green
+                    draw:
+                        icons:
+                            visible: global.icon_visible_landuse_green
+                            sprite: park
+                            priority: 41
+                            text:
+                                visible: global.text_visible_landuse_green
+                                #priority: 42
+                                font:
+                                    fill: [0.200,0.409,0.398] #*text_fill_park
+                                    style: italic
+                                    # stroke: { color: [0.870,0.870,0.870], width: 3px }
+                    natl-park-labels-z4-z6:
+                        filter: { $zoom: [4,5] }
+                        draw:
+                            icons:
+#                                visible: false
+                                text: { font: { size: 10px, stroke: { width: 2px } } }
+                    natl-park-labels-z7:
+                        filter: { $zoom: [7] }
+                        draw:
+                            icons:
+                                text: { font: { size: 10px, stroke: { width: 2px } } }
+                    natl-park-labels-z8:
+                        filter: { $zoom: [8,9] }
+                        draw:
+                            icons:
+                                text: { font: { size: 11px, stroke: { width: 2px } } }
+                    natl-park-labels-z10:
+                        filter: { $zoom: {min: 10, max: 14 } }
+                        draw:
+                            icons:
+                                text: { font: { size: 12px } }
+
+            landuse-labels-green-areas-not-national-park:
                 filter:
+                    all:
+                        - area: true
+                        - $geometry: point
+                        - kind: [park, conservation, protected_area, nature_reserve, forest, grass]
                     any:
                         # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: [14], area: { max: 200000 } }
-                        - { $zoom: [15], area: { max: 20000 } }
-                        - { $zoom: [16], area: { max: 5000 } }
-                        - { $zoom: [17], area: { max: 1000 } }
+                        - { $zoom: [5],    area: { min: 10000000000 } }
+                        - { $zoom: [6,7],  area: { min: 5000000000 } }
+                        - { $zoom: [8],    area: { min: 1000000000 } }
+                        - { $zoom: [9],    area: { min: 100000000 } }
+                        - { $zoom: [10],   area: { min: 50000000 } }
+                        - { $zoom: [11],   area: { min: 25000000 } }
+                        - { $zoom: [12],   area: { min: 5000000 } }
+                        - { $zoom: [13],   area: { min: 200000 } }
+                        - { $zoom: [14],   area: { min: 50000 } }
+                        - { $zoom: [15],   area: { min: 10000 } }
+                        - { $zoom: [16],   area: { min: 1000 } }
+                        - { $zoom: { min: 17 }, area: true }
+                not-national-park:
+                    filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
+                    draw:
+                        icons:
+                            visible: global.icon_visible_landuse_green
+                            sprite: park
+                            priority: 41
+                            text:
+                                visible: global.text_visible_landuse_green
+                                priority: 42
+                                font:
+                                    fill: [0.181,0.370,0.361]
+    #                                size: 12px
+    #                                weight: 400
+                                    style: italic
+                                    # stroke: { color: [0.870,0.870,0.870], width: 2 }
+                    green-areas-z6:
+                        # mojave national preserve
+                        filter: { $zoom: [6] }
+                        draw:
+                            icons:
+                                #visible: false
+                                text: { font: { size: 10px, stroke: { width: 2px } } }
+                    green-areas-z7:
+                        filter: { $zoom: [7] }
+                        draw:
+                            icons:
+                                #visible: false
+                                text: { font: { size: 10px } }
+                    green-areas-z8-z9:
+                        filter: { $zoom: { min: 8, max: 14 } }
+                        draw:
+                            icons:
+                                text: { font: { size: 11px } }
+                    wilderness-areas-early:
+                        filter: function() { return $zoom < 9 && feature.name && (feature.name.indexOf("Wilderness") > -1 || feature.name.indexOf("BLM") > -1 || feature.protect_class == '1' || feature.protect_class == '1a' || feature.protect_class == '1b' ); }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { visible: false }
+                    early-not-national-park:
+                        filter: { not: { kind: [national_park] }, $zoom: { max: 6 } }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { visible: false }
+                    not-national-park:
+                        filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
+                        # draw:
+                        #     icons:
+                        #         sprite: park
+                        early:
+                            filter: { $zoom: { max: 8 } }
+                            draw:
+                                icons:
+                                    visible: false
+                                    text: { visible: false }
+                    forest:
+                        filter: function() { return ( (feature.name && feature.name.indexOf("Forest") > -1) || ((feature.protect_class == 6 || feature.protect_class == '6') && feature.name.indexOf("Park") < 0) ) }
+                        draw:
+                            icons:
+                                sprite: forest
+                    hide-till-later:
+                        filter: { kind: [grass], $zoom: { max: 16 } }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { visible: false }
+                    only-text-later:
+                        filter: { kind: [grass], $zoom: { min: 16 } }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { font: { style: italic } }
+
+            battlefield:
+                filter:
+                    all:
+                        - area: true
+                        - $geometry: point
+                        - kind: [battlefield]
+#                    any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [4],  area: { min: 3000000000 } }
+#                        - { $zoom: [5],  area: { min: 3000000000 } }
+#                        - { $zoom: [6],  area: { min: 500000000 } }
+#                        - { $zoom: [7,8,9],  area: { min: 10000000 } }
+#                        - { $zoom: [10], area: { min: 5000000 } }
+#                        - { $zoom: [11], area: { min: 5000000 } }
+#                        - { $zoom: [12], area: { min: 5000000 } }
+#                        - { $zoom: [13], area: { min: 200000 } }
+#                        - { $zoom: [14], area: { min: 50000 } }
+#                        - { $zoom: { min: 15 }, area: true }
                 draw:
                     icons:
-                        visible: false
-        #end different icon sprites
+                        visible: global.icon_visible_landuse_green
+                        sprite: battlefield
+                        priority: 41
+                        text:
+                            visible: global.text_visible_landuse_green
+                            font:
+                                #fill: [0.058,0.605,0.615]
+                                # fill: [0.093,0.473,0.408]
+                                style: italic
+                                stroke: { color: global.text_stroke_park, width: 4 }
 
-        #most POI icons without name should be hidden, except these
-        no-name:
-            filter: { name: false }
-            draw:
-                icons:
-                    visible: false
-            # eg park polygons in SF that have area but no name, sigh
-            no-name-no-area:
+            beach:
                 filter:
-                    kind: true
-                    name: false
+                    all:
+                        - area: true
+                        - $geometry: point
+                        - kind: [beach]
+#                    any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [10],   area: { min: 300000 } }
+#                        - { $zoom: [11],   area: { min: 100000 } }
+#                        - { $zoom: [12],   area: { min: 50000 } }
+#                        - { $zoom: [13],   area: { min: 50000 } }
+#                        - { $zoom: [14],   area: { min: 20000 } }
+#                        - { $zoom: [15],   area: { min: 10000 } }
+#                        - { $zoom: [16],   area: { min: 1000 } }
+#                        - { $zoom: { min: 17 } }
                 draw:
                     icons:
-                        visible: false
-            sports-pitch:
+                        visible: global.icon_visible_landuse_green
+                        interactive: true
+                        sprite: beach
+                        text:
+                            visible: global.text_visible_landuse_green
+                            interactive: true
+                            font:
+                                fill: global.text_fill_beach
+                                stroke:
+                                    color: global.text_stroke_park
+            airport:
                 filter:
-                    $zoom: { min: 17 }
-                    kind: [grass, pitch]
-                    kind_detail: [baseball, basketball, football, hockey, soccer, tennis]
+                    all:
+                        - kind: [airport, aerodrome]
+                        - area: true
+                        - $geometry: point
+#                    any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [9],  area: { min: 10000000 } }
+#                        - { $zoom: [10], area: { min: 10000000 } }
+#                        - { $zoom: [11], area: { min: 5000000 } }
+#                        - { $zoom: [12], area: { min: 5000000 } }
+#                        - { $zoom: [13], area: { min: 500000 } }
+#                        - { $zoom: [14], area: { min: 20000 } }
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [15], area: { min: 10000 } }
+#                        - { $zoom: [16], area: { min: 5000 } }
+#                        - { $zoom: [17], area: { min: 2000 } }
+#                        - { $zoom: { min: 18 } }
                 draw:
                     icons:
-                        visible: global.icon_visible_poi_landuse_e
-                        priority: 69
-            z17:
+                        sprite: airport
+                        visible: global.icon_visible_landuse_green
+                        priority: 42
+                        text:
+                            visible: global.text_visible_landuse_green
+                            priority: 41
+                            text_source: global.ux_language_text_source_iata
+                            font:
+                                fill: [0.20,0.20,0.20] # *text_fill
+                                #size: 11px
+                                stroke: { color: global.text_stroke, width: 4 }
+                early:
+                    filter: { $zoom: [9,10,11] }
+                    draw: { icons: { text: { text_source: iata, font: { size: 11px } } } }
+                early2:
+                    filter: { $zoom: { min: 12, max: 14 } }
+                    draw: { icons: { text: { font: { size: 11px } } } }
+            university:
                 filter:
-                    $zoom: { min: 17 }
-                    kind: [parking]
-                draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
-            z18:
-                # for different styles, different sets
-                # since [picnic_site] doesn't have bubble-wrap icon, it's omitted here
+                    all:
+                        - kind: [university, college]
+                        - area: true
+                        - $geometry: point
+                        - not: { $layer: buildings }
+#                    any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [9],   area: { min: 10000000 } }
+#                        - { $zoom: [10], area: { min: 5000000 } }
+#                        - { $zoom: [11], area: { min: 2000000 } }
+#                        - { $zoom: [12], area: { min: 500000 } }
+#                        - { $zoom: [13], area: { min: 100000 } }
+#                        - { $zoom: [14], area: { min: 100000 } }
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [15], area: { min: 40000 } }
+#                        - { $zoom: [16], area: { min: 5000 } }
+#                        - { $zoom: [17], area: { min: 2000 } }
+#                        - { $zoom: { min: 18 } }
+                visible: global.label_visible_landuse_green
+                draw:
+                    icons:
+                        sprite: college-university
+                        visible: global.icon_visible_landuse_green
+                        priority: 41
+                        text:
+                            visible: global.text_visible_landuse_green
+                            font:
+                                weight: 600
+                                fill: [0.20,0.20,0.20]
+                                #size: 10px
+                                # stroke: { color: global.text_stroke, width: 4 }
+                early:
+                    filter: { $zoom: { max: 12 } }
+                    draw: { text-blend-order: { visible: false } }
+                early2:
+                    filter: { $zoom: { min: 12, max: 14 } }
+                    draw: { icons: { text: { font: { size: 11px } } } }
+            school:
                 filter:
-                    $zoom: { min: 18 }
-                    kind: [drinking_water, information, playground, toilets, traffic_signals]
-                draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
-            z19:
+                    all:
+                        - kind: [school, kindergarten]
+                        - area: true
+                        - $geometry: point
+                        - not: { $layer: buildings }
+                    any:
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [13], area: { min: 100000 } }
+                        - { $zoom: [14], area: { min: 50000 } }
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [15], area: { min: 10000 } }
+                        - { $zoom: [16], area: { min: 5000 } }
+                        - { $zoom: [17], area: { min: 2000 } }
+                        - { $zoom: { min: 18 }, area: true }
+                draw:
+                    icons:
+                        sprite: school
+                        visible: global.icon_visible_landuse_green
+                        priority: 41
+                        text:
+                            visible: global.text_visible_landuse_green
+                            font:
+                                fill: global.text_fill
+                                #size: 12px
+                                stroke: { color: global.text_stroke, width: 4 }
+                #early:
+#                    filter: { $zoom: { max: 14 } }
+#                    draw: { icons: { text: { font: { size: 11px } } } }
+            winter_sports:
                 filter:
-                    $zoom: { min: 19 }
-                    kind: [bicycle_parking]
-                draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
-
-        # NOTE: all natural_* should only be in landuse layer
-        suppress-icon-always:
-            filter:
-                kind: [natural_forest, natural_park, natural_wood]
-            draw:
-                icons:
-                    size: 0px
-                    priority: 100
-                    text:
-                        font:
-                            fill: '#666'
-                            family: global.text_font_family
-                            style: italic
-                            size: 11px
-        suppress-icon-z17:
-            filter:
-                $zoom: { min: 17 }
-                kind: [common, grass, houseboat, pedestrian, railway, ship, wetland]
-            draw:
-                icons:
-                    size: 0px
-                    #visible: false
-                    text: { font: { style: italic } }
-
-        # the server should be setting better values here
-        z-server-friend:
-            hide-until-z12-any:
+                    all:
+                        - kind: winter_sports
+                        - area: true
+                        - $geometry: point
+#                    any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [10], area: { min: 5000000 } }
+#                        - { $zoom: [11], area: { min: 2000000 } }
+#                        - { $zoom: [12], area: { min: 500000 } }
+#                        - { $zoom: [13], area: { min: 100000 } }
+#                        - { $zoom: [14], area: { min: 100000 } }
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [15], area: { min: 40000 } }
+#                        - { $zoom: [16], area: { min: 5000 } }
+#                        - { $zoom: [17], area: { min: 2000 } }
+#                        - { $zoom: { min: 18 } }
+                draw:
+                    icons:
+                        sprite: ski-area
+                        visible: global.icon_visible_landuse_green
+                        priority: 41
+                        text:
+                            visible: global.text_visible_landuse_green
+                            font:
+                                fill: global.text_fill
+                                size: 12px
+                                stroke: { color: global.text_stroke, width: 4 }
+                early:
+                    filter: { $zoom: { max: 14 } }
+                    draw: { icons: { text: { font: { size: 10px } } } }
+            tourism-related:
+                filter:
+                    all:
+                        - kind: [zoo, theme_park, resort, aquarium, winery, maze, stadium, enclosure, animal]
+                        - area: true
+                        - $geometry: point
+#                    any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: { min: 11 }, area: { min: 400000 } }
+#                        - { $zoom: { min: 12 }, area: { min: 200000 } }
+#                        - { $zoom: { min: 13 }, area: { min: 50000 } }
+#                        - { $zoom: { min: 14 }, area: { min: 20000 } }
+#                        - { $zoom: { min: 15 }, area: { min: 10000 } }
+#                        - { $zoom: { min: 15 }, area: { min: 2000 } }
+#                        - { $zoom: { min: 16 }, area: true }
+                draw:
+                    icons:
+                        sprite: function() { return feature.kind; }
+                        sprite_default: generic
+                        visible: global.icon_visible_poi_landuse
+                        priority: 43
+                        text:
+                            visible: global.text_visible_poi_landuse
+                            priority: 44
+                            font:
+                                fill: global.text_fill
+                                #size: 12px
+                                stroke: { color: global.text_stroke, width: 4 }
+                enclosure:
+                    filter: { kind: [enclosure, animal] }
+                    draw:
+                        icons:
+                            visible: false
+                            sprite_default: dot-black
+                        text-blend-order:
+                            text_wrap: 10
+                            font:
+                                style: italic
+                                weight: 400
+                early-sizing:
+                    filter: { $zoom: { max: 14 } }
+                    draw: { icons: { text: { font: { size: 11px } } } }
+            playgrounds_allotments_attraction_landmark_supermarket:
+                filter:
+                    all:
+                        - kind: [playground, allotments, attraction, landmark, supermarket]
+                        - area: true
+                        - $geometry: point
+#                    any:
+#                        - { $zoom: [15], area: { min: 600 } }
+#                        - { $zoom: [16], area: { min: 300 } }
+#                        - { $zoom: { min: 17 } }
+                draw:
+                    icons:
+                        visible: global.icon_visible_landuse_green
+                        priority: 41
+                        text:
+                            visible: global.text_visible_landuse_green
+                            font:
+                                size: 10px
+                                stroke: { color: global.text_stroke, width: 4 }
+                attraction:
+                    filter: { kind: [attraction] }
+                    draw:
+                        icons:
+                            sprite: attraction
+                landmark:
+                    filter: { kind: [landmark] }
+                    draw:
+                        icons:
+                            sprite: landmark
+            rest-area:
                 filter:
-                    kind: [landmark, museum, prison]
-                    $zoom: { max: 12 }
+                    all:
+                        - kind: [rest_area, service_area, rest-area]
+                        - area: true
+                        - $geometry: point
+#                    any:
+#                        - { $zoom: [12], area: { min: 30000 } }
+#                        - { $zoom: [13], area: { min: 10000 } }
+#                        - { $zoom: [14], area: { min: 5000 } }
+#                        - { $zoom: [15], area: { min: 2000 } }
+#                        - { $zoom: [16], area: { min: 1000 } }
+#                        - { $zoom: { min: 17, area: true } }
                 draw:
                     icons:
-                        visible: false
-            hide-until-z14-any:
+                        visible: global.icon_visible_landuse_green
+                        priority: 41
+                        sprite: generic
+                        text:
+                            visible: global.text_visible_landuse_green
+                            font:
+                                stroke: { color: global.text_stroke, width: 4 }
+            windmill:
                 filter:
-                    kind: [natural_forest, natural_park, natural_wood, post_office]
-                    $zoom: { max: 14 }
+                    all:
+                        - kind: [windmill]
+                        - area: true
+                        - $geometry: point
+#                    any:
+#                        - { $zoom: [14], area: { min: 500 } }
+#                        - { $zoom: [15], area: { min: 200 } }
+#                        - { $zoom: [16], area: { min: 100 } }
+#                        - { $zoom: { min: 17, area: true } }
                 draw:
                     icons:
-                        visible: false
-            hide-until-z15-any:
+                        visible: global.icon_visible_landuse_green
+                        priority: 41
+                        sprite: generic
+                        text:
+                            visible: global.text_visible_landuse_green
+                            font:
+                                stroke: { color: global.text_stroke, width: 4 }
+            campground:
                 filter:
-                    $zoom: { max: 15 }
-                    kind: [cafe, restaurant]
+                    all:
+                        - kind: [campground, camp_site, caravan_site]
+                        - area: true
+                        - $geometry: point
+#                    any:
+#                        - { $zoom: [13], area: { min: 10000 } }
+#                        - { $zoom: [14], area: { min: 5000 } }
+#                        - { $zoom: [15], area: { min: 2000 } }
+#                        - { $zoom: [16], area: { min: 1000 } }
+#                        - { $zoom: { min: 17, area: true } }
                 draw:
                     icons:
-                        visible: false
-            hide-until-z15-no-area:
+                        visible: global.icon_visible_landuse_green
+                        priority: 41
+                        sprite: campground
+                        text:
+                            visible: global.text_visible_landuse_green
+                            font:
+                                stroke: { color: global.text_stroke, width: 4 }
+            glacier:
                 filter:
-                    area: false
-                    $zoom: { max: 15 }
-                    kind: [park]
+                    all:
+                        - kind: glacier
+                        - area: true
+                        - $geometry: point
+#                    any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [10],    area: { min: 20000000 } }
+#                        - { $zoom: [11],    area: { min: 5000000 } }
+#                        - { $zoom: [12],    area: { min: 2000000 } }
+#                        - { $zoom: [13],    area: { min: 500000 } }
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: { min: 14 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z15-with-area:
-                filter:
-                    area: true
-                    $zoom: { max: 15 }
-                    kind: [nursing_home]
+                    text-blend-order:
+                        visible: true
+                        priority: 44
+                        interactive: true
+                        text_wrap: 10
+                        font:
+                            weight: 400
+                            style: italic
+                            fill: '#4ba3c5'
+
+            station-train-subway:
+                filter: { kind: [station, train-station, train_station], $zoom: { min: 11 } }
+                visible: global.label_visible_station
                 draw:
                     icons:
-                        visible: false
-            hide-until-z16-any:
+                        visible: global.icon_visible_station
+                        sprite: train-station
+                        size: [[13, 12px], [14, 12px], [15, 16px], [17, 18px], [18, 20px]]
+                        priority: 42
+                        text:
+                            visible: global.text_visible_station
+                            font:
+                                fill: [0.20,0.20,0.20] # *text_fill
+                                # size: 10px
+                                weight: 600
+                                stroke: { color: global.text_stroke, width: 4 }
+                low-priority-early:
+                    filter: { kind_tile_rank: { min: 5 }, $zoom: { min: 0, max: 13 } }
+                    draw:
+                        icons:
+                            visible: false
+                            #size: [[12, 10px], [14, 10px], [15, 16px]]
+                            text: { visible: false }
+                low-priority-early-z13:
+                    filter: { kind_tile_rank: { min: 5 }, $zoom: [13] }
+                    draw:
+                        icons:
+                            visible: false
+                            #size: [[12, 10px], [14, 10px], [15, 16px]]
+                            text: { visible: false }
+                low-priority-early-z14:
+                    filter: { kind_tile_rank: { min: 7 }, $zoom: [14] }
+                    draw:
+                        icons:
+                            #size: [[14, 11px], [15, 16px], [17, 18px], [18, 20px]]
+                            #visible: false
+                            text: { visible: false }
+
+            landuse-labels-not-any-above:
                 filter:
-                    kind: [fire_station, grass, peak, police, tram_stop]
-                    $zoom: { max: 16 }
+                    all:
+                        - $zoom: { min: 6 }
+                        - area: true
+                        - $geometry: point
+                        - not: { kind: [park, national_park, battlefield, conservation, protected_area, nature_reserve, forest, grass, beach, airport, aerodrome, university, college, school, kindergarten, winter_sports, zoo, theme_park, resort, aquarium, winery, maze, stadium, playground, allotments, attraction, landmark, glacier, station] }
+#                    any:
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [5,6,7], area: { min: 5000000000 } }
+#                        - { $zoom: [8],     area: { min: 1600000000 } }
+#                        - { $zoom: [9],     area: { min: 400000000 } }
+#                        - { $zoom: [10],    area: { min: 100000000 } }
+#                        - { $zoom: [11],    area: { min: 25000000 } }
+#                        - { $zoom: [12],    area: { min: 5000000 } }
+#                        - { $zoom: [13],    area: { min: 1000000 } }
+#                        - { $zoom: [14],    area: { min: 100000 } }
+#                        # show labels for smaller landuse areas at higher zooms
+#                        - { $zoom: [15],    area: { min: 5000 } }
+#                        - { $zoom: [16],    area: { min: 2000 } }
+#                        - { $zoom: { min: 17 }, area: true }
                 draw:
                     icons:
-                        visible: false
-            hide-until-z16-no-area:
-                filter:
-                    area: false
-                    kind: [allotments, college, garden, university]
-                    $zoom: { max: 16 }
+                        sprite: function() { return feature.kind; }
+                        sprite_default: generic
+                        visible: global.icon_visible_poi_landuse
+                        priority: 43
+                        text:
+                            visible: global.text_visible_poi_landuse
+                            font:
+                                fill: [0.20,0.20,0.20] # *text_fill
+    #                            size: 10px
+                                weight: 600
+                                stroke: { color: global.text_stroke, width: 4 }
+                early-sizing:
+                    filter: { $zoom: { max: 14 } }
+                    draw: { text-blend-order: { size: 11px } }
+                building-like:
+                    filter: { kind: [commercial,residential,warehouse,public,dormitory], osm_relation: false }
+                    draw:
+                        icons:
+                            sprite: building
+#                residential-relations-paris-wtf:
+#                    filter: { kind: [residential], osm_relation: true }
+#                    draw:
+#                        icons:
+#                            text: { visible: true, text_source: short_name, font: { fill: red } }
+#                            icons: { sprite: park, visible: true }
+                hide-till-later:
+                    filter: { kind: [pedestrian,common,railway,ship,houseboat,common,grass,wetland,pitch], $zoom: { max: 17 } }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { visible: false }
+                only-text-later:
+                    filter: { kind: [pedestrian,common,railway,ship,houseboat,common,grass,wetland], $zoom: { min: 17 } }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { font: { style: italic } }
+                burial_vault-early:
+                    filter: { kind: [burial_vault], $zoom: { max: 19 } }
+                    draw:
+                        icons:
+                            visible: false
+                            text:  { visible: false }
+                hide-early:
+                   filter: { kind: [cafe, restaurant, nursing_home], $zoom: { max: 15 } }
+                   draw:
+                       icons:
+                           visible: false
+                garden-area-early:
+                   filter:
+                       all:
+                           - kind: [garden, allotments]
+                       any:
+                           # limit show smaller landuse areas to higher zooms
+                           - { $zoom: [12], area: { max: 500000 } }
+                           - { $zoom: [13], area: { max: 100000 } }
+                           - { $zoom: [14], area: { max: 10000 } }
+                           - { $zoom: [15], area: { max: 5000 } }
+                   draw:
+                       icons:
+                           visible: false
+#                z-other-tier6-early:
+#                    filter:
+#                        all:
+#                            - kind: [garden, allotments, parking, pedestrian, common, pitch, place_of_worship, playground, school, nursing_home]
+#                        any:
+#                            # limit show smaller landuse areas to higher zooms
+#                            - { $zoom: { max: 12 } }
+#                            - { $zoom: [12], area: { max: 500000 } }
+#                            - { $zoom: [13], area: { max: 10000 } }
+#                            - { $zoom: [14], area: { max: 4000 } }
+#                            - { $zoom: [15], area: { max: 2000 } }
+#                    draw:
+#                        icons:
+#                            visible: false
+
+            university-poi:
+                filter: { kind: [university, college], area: false, $zoom: { max: 16 } }
                 draw:
                     icons:
                         visible: false
-            # no POIs for commercial, residential
-            hide-until-z17-any:
+                        text:  { visible: false }
+            office-early:
                 filter:
-                    $zoom: { max: 17 }
-                    kind: [bank, bus_stop, car_sharing, wood, platform]
+                    any:
+                        - { kind: [insurance, office, company], $zoom: [15], area: { max: 10000 } }
+                        - { kind: [insurance, office, company], $zoom: [16], area: { max: 5000 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z17-with-area:
-                filter:
-                    area: true
-                    $zoom: { max: 17 }
-                    kind: [common, grass, houseboat, pedestrian, pitch, railway, ship, wetland]
+                        text:  { visible: false }
+            bank-early:
+                filter: { kind: [bank], $zoom: { max: 17 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z17-no-area:
-                filter:
-                    area: false
-                    $zoom: { max: 17 }
-                    # note: atm and drinking_water appear hear and in area versions
-                    kind: [accountant, administrative, advertising_agency, animal, architect, association, atm, bakery, bed_and_breakfast, bicycle, bicycle_parking, bicycle_rental_station, books, butcher, car, car_repair, chalet, clothes, company, computer, consulting, convenience, doityourself, drinking_water, dry_cleaning, educational_institution, emergency_phone, employment_agency, estate_agent, fashion, financial, florist, foundation, gift, government, greengrocer, guest_house, hairdresser, hostel, hotel, insurance, it, jewelry, lawyer, mast, memorial, mobile_phone, motel, newspaper, ngo, notary, optician, parking, pet, physician, playground, political_party, post_box, religion, research, subway_entrance, tax_advisor, telecommunication, telephone, theatre, therapist, toilets, traffic_signals, travel_agent, water_tower]
+                        text:  { visible: false }
+            garden-no-area-early2:
+                filter: { kind: [garden, allotments], $zoom: { max: 16 }, area: false }
                 draw:
                     icons:
                         visible: false
-            hide-until-z18-any:
-                filter:
-                    kind: [atm, bus_stop, drinking_water]
-                    $zoom: { max: 18 }
+            garden-no-area-early:
+                filter: { kind: [garden, allotments], $zoom: [16], area: false }
                 draw:
                     icons:
-                        visible: false
-            hide-until-z18-no-area:
-                filter:
-                    $zoom: { max: 18 }
-                    area: false
-                    kind: [bench, parking, waste_basket]
+                        priority: 45
+                        size: 14px
+                        text:  { font: { size: 10px, style: italic } }
+            garden-no-area-later:
+                filter: { kind: [garden, allotments], $zoom: { min: 17 }, area: false }
+                draw:
+                    icons:
+                        priority: 45
+                        size: 16px
+                        text:  { font: { size: 11px, style: italic } }
+            post-office-early:
+                filter: { kind: [post_office], $zoom: { max: 14 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z19-any:
-                filter:
-                    $zoom: { max: 19 }
-                    kind: [bicycle_parking, burial_vault, car_sharing]
+                        text:  { visible: false }
+            atm-early:
+                filter: { kind: [atm], $zoom: { max: 18 } }
                 draw:
                     icons:
                         visible: false
-
-            # hide based on kind and area filters
-            military-early:
-                filter:
-                    kind: [military]
-                    any:
-                        # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: [8], area: { max: 50000000 } }
+                        text:  { visible: false }
+            bicycle-parking-early:
+                filter: { kind: [bicycle_parking], $zoom: { max: 19 } }
                 draw:
                     icons:
                         visible: false
-            university-early:
-                filter:
-                    kind: [university, college]
-                    any:
-                        # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: [11], area: { max: 2000000 } }
-                        - { $zoom: [12], area: { max: 500000 } }
+                        text:  { visible: false }
+            gate:
+                filter: { kind: gate, name: true  }
+                draw: { icons: { sprite: generic } }
+            yes-early:
+                filter: { kind: [yes], $zoom: { max: 18 } }
                 draw:
                     icons:
                         visible: false
-            school-early:
-                filter:
-                    kind: [school, kindergarten]
-                    any:
-                        # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: [13], area: { max: 100000 } }
-                        - { $zoom: [14], area: { max: 50000 } }
-                        - { $zoom: [15], area: { max: 10000 } }
-                        - { $zoom: [16], area: { max: 5000 } }
-                        - { $zoom: [17], area: { max: 2000 } }
+                        text:  { visible: false }
+            peak-early:
+                filter: { kind: [peak], $zoom: { max: 16 } }
                 draw:
                     icons:
                         visible: false
-            garden-area-early:
-                filter:
-                    kind: [garden, allotments]
-                    any:
-                        # limit show smaller landuse areas to higher zooms
-                        - { $zoom: [12], area: { max: 500000 } }
-                        - { $zoom: [13], area: { max: 100000 } }
-                        - { $zoom: [14], area: { max: 10000 } }
-                        - { $zoom: [15], area: { max: 5000 } }
+                        text:  { visible: false }
+            drinking-water-early:
+                filter: { kind: [drinking_water], $zoom: { max: 18 } }
                 draw:
                     icons:
                         visible: false
-            cemetery-early:
-                filter:
-                    kind: [cemetery]
-                    # limit show smaller landuse areas to higher zooms
-                    any:
-                        - { $zoom: [12], area: { max: 3000000 } }
+                        text:  { visible: false }
+            memorial-early:
+                filter: { kind: [memorial], $zoom: { max: 13 } }
                 draw:
                     icons:
                         visible: false
-            golf_course-early:
-                filter:
-                    kind: golf_course
-                    any:
-                        - { $zoom: [12], area: { max: 2500000 } }
+                        text:  { visible: false }
+            animal-points-early:
+                filter: { kind: [animal], area: false, $zoom: { max: 18 } }
                 draw:
                     icons:
                         visible: false
-            office-early:
+                        text:  { visible: false }
+#            animal-areas-early:
+#                filter: { kind: [animal], area: { min: 500 }, $zoom: { max: 18 } }
+#                draw:
+#                    icons:
+#                       visible: false
+#                       text:  { visible: false }
+            parking-labels-early:
                 filter:
-                    - { kind: [insurance, office, company], $zoom: [15], area: { max: 10000 } }
-                    - { kind: [insurance, office, company], $zoom: [16], area: { max: 5000 } }
+                    kind: [parking]
+                    $zoom: { max: 18 }
                 draw:
                     icons:
                         visible: false
-            landuse-labels-green-areas-not-national-park:
+                        text:
+                            visible: false
+            parking-labels:
                 filter:
-                    kind: [park, conservation, protected_area, nature_reserve, forest, grass]
-                    any:
-                    # show labels for smaller landuse areas at higher zooms
-                    - { $zoom: { max: 6 }, area: true }
-                    - { $zoom: [6],    area: { max: 5000000000 } }
-                    - { $zoom: [7],    area: { max: 5000000000 } }
-                    - { $zoom: [8],    area: { max: 1000000000 } }
-                    - { $zoom: [9],    area: { max: 100000000 } }
-                    - { $zoom: [10],   area: { max: 50000000 } }
-                    - { $zoom: [11],   area: { max: 25000000 } }
-                    - { $zoom: [12],   area: { max: 5000000 } }
-                    - { $zoom: [13],   area: { max: 200000 } }
-                    - { $zoom: [14],   area: { max: 50000 } }
-                    - { $zoom: [15],   area: { max: 10000 } }
-                    - { $zoom: [16],   area: { max: 1000 } }
+                    kind: [parking]
+                    $zoom: { min: 18 }
                 draw:
                     icons:
-                        visible: false
-                wilderness-areas-early:
-                    filter: function() { return $zoom < 9 && feature.name && (feature.name.indexOf("Wilderness") > -1 || feature.name.indexOf("BLM") > -1 || feature.protect_class == '1' || feature.protect_class == '1a' || feature.protect_class == '1b' ); }
+                        text:
+                            visible: global.text_visible_poi_landuse
+                            font:
+                                fill: [0.20,0.20,0.20] #*text_fill
+                                size: 10px
+                                stroke: { color: global.text_stroke, width: 4 }
+            landuse-funky:
+                filter: { kind: [commercial, residential, wood], $zoom: { max: 17 } }
+                draw:
+                    icons:
+                        text:
+                            visible: false
+            car-sharing:
+                filter: { kind: car_sharing }
+                icons-early:
+                    filter: { $zoom: { max: 17 } }
                     draw:
                         icons:
                             visible: false
-                not-national-park:
-                    filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
-                    early:
-                        filter: { $zoom: { max: 8 } }
-                        draw:
-                            icons:
+                text-labels-early:
+                    filter: { $zoom: { max: 19 } }
+                    draw:
+                        icons:
+                            text:
                                 visible: false
-            landuse-labels-not-any-above:
-                filter:
-                    $zoom: { max: 6 }
-                    not: { kind: [aerodrome, airport, allotments, aquarium, attraction, battlefield, beach, cemetery, college, conservation, forest, garden, glacier, golf_course, grass, kindergarten, landmark, maze, national_park, nature_reserve, park, playground, protected_area, resort, school, stadium, station, theme_park, university, winery, winter_sports, zoo] }
+            tower:
+                filter: { kind: [tower], label_placement: true }
                 draw:
                     icons:
                         visible: false
-            glacier:
-                filter: { $zoom: { max: 14 }, kind: glacier, area: false }
+                        text:
+                            font:
+                                style: italic
+            tram-stop-early:
+                filter: { kind: tram_stop, $zoom: { max: 15 } }
                 draw:
                     icons:
                         visible: false
-
-        # set special priority, sprite, and text styles per kind
-        # has-area:
-        #     filter: { area: true }
-        #     draw:
-        #         icons:
-        #             priority: 41
-
-        national-park-protected-areas:
-            filter:
-                kind: [national_park, battlefield]
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    sprite: park
-                    text:
-                        visible: global.text_visible_landuse_green
-                        font:
-                            fill: [0.200,0.409,0.398] #*text_fill_park
-                            style: italic
-            z14-parks:
-                filter: { $zoom: { min: 14 } }
+            tram-stop-early-z15:
+                filter: { kind: tram_stop, $zoom: [15] }
                 draw:
                     icons:
-                        sprite: park-l
-                        size: global.icon_size_green_l
-        parks:
-            filter:
-                - kind: [park, conservation, grass]
-                - { kind: protected_area, not: { protect_class: [6, '6'] } }
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    sprite: park
-                    text:
-                        visible: global.text_visible_landuse_green
-                        font:
-                            fill: [0.181,0.370,0.361]
-                            style: italic
-            only-text-later:
-                filter: { kind: [grass], $zoom: { min: 16 } }
+                        text:
+                            visible: false
+            tram-stop:
+                filter: { kind: tram_stop, $zoom: { min: 15 } }
+                draw:
+                    icons:
+                        size: [[13, 12px], [16, 18px]]
+                        #text:
+                        #    offset: [[13, [0, 6px]], [16, [0, 9px]]]
+            glaciers-pois:
+                filter: { $zoom: { min: 14 }, kind: glacier, area: false }
                 draw:
                     icons:
-                        size: 0px
+                        visible: false
                         text:
-                            font:
-                                style: italic
-        forest:
-            filter:
-                - kind: forest
-                - { kind: protected_area, protect_class: [6, '6'] }
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    sprite: forest
-                    text:
-                        visible: global.text_visible_landuse_green
-                        font:
-                            fill: [0.181,0.370,0.361]
-                            style: italic
-        beach:
-            filter:
-                kind: [beach]
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    text:
-                        visible: global.text_visible_landuse_green
-                        font:
-                            fill: global.text_fill_beach
-        airport:
-            filter:
-                kind: [airport, aerodrome]
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    priority: 42
-                    text:
-                        visible: global.text_visible_landuse_green
-                        text_source: global.ux_language_text_source_iata
-            early:
-                filter: { $zoom: [9,10,11] }
-                draw: { icons: { text: { text_source: iata } } }
-
-        enclosure-related:
-            filter:
-                kind: [enclosure, animal]
-            draw:
-                icons:
-                    priority: 43
-                    size: 0px
-                    #: dot-black
-                    text:
-                        text_wrap: 10
-                        font:
-                            style: italic
-                            weight: normal
-        glacier:
-            filter:
-                kind: glacier
-            draw:
-                icons:
-                    size: 0px
-                    #visible: false
-                    text:
-                        visible: true
-                        priority: 44
+                            visible: false
+                    text-blend-order:
+                        visible: false
+                        priority: 45
+                        interactive: true
                         text_wrap: 10
                         font:
-                            weight: normal
+                            weight: 400
                             style: italic
                             fill: '#4ba3c5'
-
-        # landuse-labels-not-any-above:
-        #     filter:
-        #         not: { kind: [aerodrome, airport, allotments, aquarium, attraction, battlefield, beach, cemetery, college, conservation, forest, garden, glacier, golf_course, grass, kindergarten, landmark, maze, national_park, nature_reserve, park, playground, protected_area, resort, school, stadium, station, theme_park, university, winery, winter_sports, zoo] }
-        #     draw:
-        #         icons:
-        #             priority: 43
-
-        building-like:
-            filter: { kind: [commercial,residential,warehouse,public,dormitory], osm_relation: false }
-            draw:
-                icons:
-                    sprite: building
-
-        station-train-subway:
-            filter: { kind: [station, train_station] }
-            draw:
-                icons:
-                    visible: global.icon_visible_station
-                    size: [[13, 12px], [14, 12px], [15, 16px], [17, 18px], [18, 20px]]
-                    priority: 42
-                    text:
-                        visible: global.text_visible_station
-            station-early:
+            bus-stop-bus-station-labels:
                 filter:
-                    $zoom: { max: 11 }
-                draw:
-                    icons:
-                        visible: false
-            # for a transit style we'd want to see **all**, so don't move this above (it's special to this style)
-            low-priority-early:
-                filter: { kind_tile_rank: { min: 5 }, $zoom: { min: 0, max: 13 } }
+                    kind: [bus_stop, bus_station]
                 draw:
                     icons:
-                        visible: false
-            low-priority-early-z13:
-                filter: { kind_tile_rank: { min: 5 }, $zoom: [13] }
-                draw:
-                    icons:
-                        visible: false
-            low-priority-early-z14:
-                filter: { kind_tile_rank: { min: 7 }, $zoom: [14] }
-                draw:
-                    icons:
-                        text: { visible: false }
-
-        garden-no-area-early:
-            filter: { kind: [garden, allotments], $zoom: [16], area: false }
-            draw:
-                icons:
-                    priority: 45
-                    size: 14px
-                    text:  { font: { size: 10px, style: italic } }
-        garden-no-area-later:
-            filter: { kind: [garden, allotments], $zoom: { min: 17 }, area: false }
-            draw:
-                icons:
-                    priority: 45
-                    size: 16px
-                    text:  { font: { size: 11px, style: italic } }
-        gate:
-            filter: { kind: gate, name: true  }
-            draw: { icons: { sprite: generic } }
-
-        parking-labels:
-            filter:
-                kind: [parking]
-                $zoom: { min: 18 }
-            draw:
-                icons:
-                    text:
-                        visible: global.text_visible_poi_landuse
-                        font:
-                            size: 10px
-        tower:
-            filter: { kind: [tower], label_placement: true }
-            draw:
-                icons:
-                    size: 0px
-                    #visible: false
-                    text:
-                        font:
-                            style: italic
-
-        # TODO: this isn't working, should see small icons near the transbay terminal in SF
-        bus_stop:
-            filter:
-                kind: [bus_stop]
-            draw:
-                icons:
-                    size: 14px
-                    text:
-                        font:
-                            size: 11px
-                            weight: normal
-            later:
-                filter: { $zoom: { max: 19 } }
+                        text:
+                            visible: global.text_visible_poi_landuse
+                            font:
+                                fill: [0.20,0.20,0.20] # *text_fill
+                                size: 11px
+                                stroke: { color: global.text_stroke, width: 4 }
+                bus-stop-early1:
+                    filter:
+                        kind: [bus_stop]
+                        $zoom: { max: 18 }
+                    draw:
+                        icons:
+                            visible: false
+                bus_stop-early2:
+                    filter:
+                        kind: [bus_stop]
+                        $zoom: { max: 19 }
+                    draw:
+                        icons:
+                            size: [[13, 8px], [19, 18px]]
+                            text:
+                                visible: false
+            minor-z17-early:
+                filter:
+                    kind: [accountant, administrative, advertising_agency, architect, association, atm, bakery, bed_and_breakfast, bicycle, bicycle_parking, bicycle_rental_station, books, butcher, car, car_repair, chalet, clothes, company, computer, consulting, convenience, doityourself, drinking_water, dry_cleaning, educational_institution, emergency_phone, employment_agency, estate_agent, fashion, financial, florist, foundation, gift, government, greengrocer, guest_house, hairdresser, hostel, hotel, insurance, it, jewelry, lawyer, mast, memorial, mobile_phone, motel, newspaper, ngo, notary, optician, parking, pet, physician, playground, political_party, post_box, religion, research, subway_entrance, tax_advisor, telecommunication, telephone, theatre, therapist, toilets, traffic_signals, travel_agent, water_tower, yes]
+                    area: false
+                    $zoom: { max: 17 }
                 draw:
                     icons:
-                        text:
-                            visible: false
+                        visible: false
+                        text:  { visible: false }
+            minor-z18-early:
+                filter:
+                    kind: [bench, waste_basket]
+                    area: false
+                    $zoom: { max: 18 }
+                draw:
+                    icons:
+                        visible: false
+                        text:  { visible: false }
+
+            icons:
+                adult-boutique:
+                    filter: { kind: [erotic, adult_boutique] }
+                    draw:   { icons: { sprite: adult-boutique } }
+                allotments:
+                    filter: { kind: [allotments] }
+                    draw:   { icons: { sprite: garden } }
+                airport:
+                    filter: { kind: [airport, aerodrome] }
+                    draw:   { icons: { sprite: airport } }
+                animal-shelter:
+                    filter: { kind: [animal_shelter, animal-shelter, animal_boarding] }
+                    draw:   { icons: { sprite: animal-shelter } }
+                antique-shop:
+                    filter: { kind: [antiques, antique-shop] }
+                    draw:   { icons: { sprite: antique-shop } }
+                art-gallery:
+                    filter: { kind: [art_gallery, art-gallery, art, artwork] }
+                    draw:   { icons: { sprite: art-gallery } }
+                athletics-sports:
+                    filter: { kind: [athletic_sports, recreation_ground, sports_centre] }
+                    draw:   { icons: { sprite: athletics-sports } }
+                automotive-shop:
+                    filter: { kind: [car_repair, automotive-shop, automotive, tyres] }
+                    draw:   { icons: { sprite: automotive-shop } }
+                bakery:
+                    filter: { kind: [bakery, pastry, chocolate] }
+                    draw:   { icons: { sprite: bakery } }
+                bar:
+                    filter: { kind: [pub, bar] }
+                    draw:   { icons: { sprite: bar } }
+                beer-garden:
+                    filter: { kind: [biergarten, beer-garden, brewery] }
+                    draw:   { icons: { sprite: beer-garden } }
+                bike-shop:
+                    filter: { kind: [bicycle, bicycle_rental, bike, bike_shop, bicycle_rental_station] }
+                    draw:   { icons: { sprite: bike-shop } }
+                bicycle-parking:
+                    filter: { kind: [bicycle_parking] }
+                    draw:   { icons: { sprite: bicycle-parking } }
+                boat-ferry:
+                    filter: { kind: [ferry_terminal, boat-ferry, ferry-boat, ferry] }
+                    draw:   { icons: { sprite: boat-ferry } }
+                boat-ramp:
+                    filter: { kind: [slipway, boat-ramp, boat_ramp] }
+                    draw:   { icons: { sprite: boat-ramp } }
+                bookstore:
+                    filter: { kind: [books, bookstore] }
+                    draw:   { icons: { sprite: bookstore } }
+                bowling-alley:
+                    filter: { kind: [bowling_alley, bowling-alley] }
+                    draw:   { icons: { sprite: bowling-alley } }
+                bridal-shop:
+                    filter: { kind: [bridal, bridal-shop] }
+                    draw:   { icons: { sprite: bridal-shop } }
+                building-icon:
+                    filter: { kind: [building, auditorium, terminal, hangar, retirement_home, manor, recreation_center, apartments] }
+                    draw:   { icons: { sprite: building } }
+                    early:
+                        filter:
+                            any:
+                                # show labels for smaller landuse areas at higher zooms
+                                - { $zoom: [14], area: { max: 200000 } }
+                                - { $zoom: [15], area: { max: 20000 } }
+                                - { $zoom: [16], area: { max: 5000 } }
+                                - { $zoom: [17], area: { max: 1000 } }
+                        draw:
+                            icons:
+                                visible: false
+                                text:
+                                    visible: false
+                burger:
+                    filter: { kind: [fast_food, burger] }
+                    draw:   { icons: { sprite: burger } }
+                taqueria:
+                    filter: { kind: [burrito,taqueria] }
+                    draw:   { icons: { sprite: taqueria } }
+                bus-station:
+                    filter: { kind: [bus_stop, bus_station] }
+                    draw:   { icons: { sprite: bus-station } }
+                camera-store:
+                    filter: { kind: [camera, camera-store, photo] }
+                    draw:   { icons: { sprite: camera-store } }
+                campground:
+                    filter: { kind: [campground, camp_site, caravan_site] }
+                    draw:   { icons: { sprite: campground } }
+                candy-store:
+                    filter: { kind: [candy, candy-store, confectionery] }
+                    draw:   { icons: { sprite: candy-store } }
+                car-dealership:
+                    filter: { kind: [car, car-dealership] }
+                    draw:   { icons: { sprite: car-dealership } }
+                car-wash:
+                    filter: { kind: [car_wash, car-wash] }
+                    draw:   { icons: { sprite: car-wash } }
+                castle:
+                    filter: { kind: [castle, fort] }
+                    draw:   { icons: { sprite: castle } }
+                cemetery:
+                    filter: { kind: [grave_yard, cemetery] }
+                    draw:   { icons: { sprite: cemetery } }
+                cheese-shop:
+                    filter: { kind: [cheese, cheese-shop] }
+                    draw:   { icons: { sprite: cheese-shop } }
+                clothing-store:
+                    filter: { kind: [clothes, chothing-store, "clothes store", fashion] }
+                    draw:   { icons: { sprite: clothing-store } }
+                coffee-shop:
+                    filter: { kind: [cafe, coffee-shop] }
+                    draw:   { icons: { sprite: coffee-shop } }
+                college-university:
+                    filter: { kind: [university, college, college-university], area: false }
+                    draw:   { icons: { sprite: college-university } }
+                concert-hall:
+                    filter: { kind: [music_venue] }
+                    draw:   { icons: { sprite: concert-hall } }
+                convenience-store:
+                    filter: { kind: [convenience, convenience-store, convenience_store, beverages] }
+                    draw:   { icons: { sprite: convenience-store } }
+                cosmetics-shop:
+                    filter: { kind: [cosmetics, cosmetics-shop, beauty] }
+                    draw:   { icons: { sprite: cosmetics-shop } }
+                department-store:
+                    filter: { kind: [department_store, department-store] }
+                    draw:   { icons: { sprite: department-store } }
+                doctors:
+                    filter: { kind: [doctors, clinic] }
+                    draw:   { icons: { sprite: doctors } }
+                dog-park:
+                    filter: { kind: [dog_park, dog_run, dog-run] }
+                    draw:   { icons: { sprite: dog-park } }
+                drinking-water:
+                    filter: { kind: drinking_water }
+                    draw: { icons: { sprite: drinking-water } }
+                dry-cleaning:
+                    filter: { kind: [dry_cleaning] }
+                    draw:   { icons: { sprite: dry-cleaning } }
+                electronics-store:
+                    filter: { kind: [electronics, electronics-store, computer] }
+                    draw:   { icons: { sprite: electronics-store } }
+                factory:
+                    filter: { kind: [factory, industrial, chimney, sub_station, substation, wastewater_plant, works, water_works, plant, generator] }
+                    draw:   { icons: { sprite: factory } }
+                farmers-market:
+                    filter: { kind: [farmers_market, farmers-market] }
+                    draw:   { icons: { sprite: farmers-market } }
+                fire-station:
+                    filter: { kind: [fire_station, fire-station] }
+                    draw:   { icons: { sprite: fire-station } }
+                fish-market:
+                    filter: { kind: [fish, fish-market, seafood, fishmonger] }
+                    draw:   { icons: { sprite: fish-market } }
+                fishing-area:
+                    filter: { kind: [fishing_area, fishing-spot, fishing] }
+                    draw:   { icons: { sprite: fishing-area } }
+                fitness:
+                    filter: { kind: [gym, fitness, fitness_center] }
+                    draw:   { icons: { sprite: fitness } }
+                flea-market:
+                    filter: { kind: [flea_market, flea-market] }
+                    draw:   { icons: { sprite: flea-market } }
+                flower-shop:
+                    filter: { kind: [florist, flower-shop] }
+                    draw:   { icons: { sprite: flower-shop } }
+                forest:
+                    filter: { kind: [forest, conservation, wood] }
+                    draw:   { icons: { sprite: forest } }
+                furniture-store:
+                    filter: { kind: [furniture, furniture-store] }
+                    draw:   { icons: { sprite: furniture-store } }
+                garden-center:
+                    filter: { kind: [garden_centre, garden_center] }
+                    draw:   { icons: { sprite: garden-center } }
+                gas:
+                    filter: { kind: [gas, gas_canister] }
+                    draw:   { icons: { sprite: gas } }
+                gas-station:
+                    filter: { kind: [fuel, gas-station] }
+                    draw:   { icons: { sprite: gas-station } }
+                general-entertainment:
+                    filter: { kind: [ticket, general_entertainment] }
+                    draw:   { icons: { sprite: general-entertainment } }
+                generic:
+                    filter: { kind: [generic] }
+                    draw:   { icons: { sprite: generic } }
+                gift-shop:
+                    filter: { kind: [gift, gift-shop] }
+                    draw:   { icons: { sprite: gift-shop } }
+                golf-course:
+                    filter: { kind: [golf-course, golf_course] }
+                    draw:   { icons: { sprite: golf-course } }
+                government-building:
+                    filter: { kind: [townhall, public_building, embassy] }
+                    draw:   { icons: { sprite: government-building } }
+                grocery-store:
+                    filter: { kind: [supermarket, grocery-store, health_food, greengrocer] }
+                    draw:   { icons: { sprite: grocery-store } }
+                harbor-marina:
+                    filter: { kind: [marina, harbor, harbor-marina, harbor_marina, dock, mooring] }
+                    draw:   { icons: { sprite: harbor-marina } }
+                hardware-store:
+                    filter: { kind: [hardware, hardware-store, doityourself, paint] }
+                    draw:   { icons: { sprite: hardware-store } }
+                hotel:
+                    filter: { kind: [hotel, motel, hostel] }
+                    draw:   { icons: { sprite: hotel } }
+                hot_spring:
+                    filter: { kind: [hot_spring] }
+                    draw:   { icons: { sprite: hot-spring } }
+                hunting:
+                    filter: { kind: [hunting] }
+                    draw:   { icons: { sprite: hunting } }
+                ice-cream-shop:
+                    filter: { kind: [ice_cream] }
+                    draw:   { icons: { sprite: ice-cream-shop } }
+                information:
+                    filter: { kind: [info, information] }
+                    draw:   { icons: { sprite: information } }
+                jewelry-store:
+                    filter: { kind: [jewelry, jewelry_store, jewelry-store] }
+                    draw:   { icons: { sprite: jewelry-store } }
+                landmark:
+                    filter: { kind: [landmark, memorial, monument, wayside_shrine, beacon] }
+                    draw:   { icons: { sprite: landmark } }
+                tower:
+                    filter: { kind: [tower], label_placement: false }
+                    draw:   { icons: { sprite: landmark } }
+                laundry:
+                    filter: { kind: [laundry] }
+                    draw:   { icons: { sprite: laundry } }
+                light-rail:
+                    filter: { kind: [light-rail, light_rail, tram_stop] }
+                    draw:   { icons: { sprite: light-rail } }
+                liquor-store:
+                    filter: { kind: [alcohol, liquor-store, liquor] }
+                    draw:   { icons: { sprite: liquor-store } }
+                market:
+                    filter: { kind: [market, variety_store, boutique, dairy, retail] }
+                    draw:   { icons: { sprite: market } }
+                mine:
+                    filter: { kind: [mine, quarry, mineshaft, adit] }
+                    draw:   { icons: { sprite: mine } }
+                miscellaneous-shop:
+                    filter: { kind: [houseware, miscellaneous-shop] }
+                    draw:   { icons: { sprite: miscellaneous-shop } }
+                mobile-phone-shop:
+                    filter: { kind: [mobile_phone] }
+                    draw:   { icons: { sprite: mobile-phone-shop } }
+                motorcycle-shop:
+                    filter: { kind: [motorcycle, motorcycle_shop, motorcycle_repair] }
+                    draw:   { icons: { sprite: motorcycle-shop } }
+                mountain:
+                    filter: { kind: [mountain, peak] }
+                    draw:   { icons: { sprite: mountain } }
+                movie-theatre:
+                    filter: { kind: [cinema, movie-theatre, movie-theater] }
+                    draw:   { icons: { sprite: movie-theatre } }
+                museum:
+                    filter: { kind: [museum, observatory] }
+                    draw:   { icons: { sprite: museum } }
+                music-store:
+                    filter: { kind: [music, music-store, musical_instrument] }
+                    draw:   { icons: { sprite: music-store } }
+                newsstand:
+                    filter: { kind: [kiosk, newsstand, newsagent] }
+                    draw:   { icons: { sprite: newsstand } }
+                nightlife:
+                    filter: { kind: [nightclub, nightlife] }
+                    draw:   { icons: { sprite: nightlife } }
+                office:
+                    filter: { kind: [insurance, office, company] }
+                    draw:   { icons: { sprite: office } }
+                office-supplies:
+                    filter: { kind: [office_supplies, office-supplies, stationery] }
+                    draw:   { icons: { sprite: office-supplies } }
+                optical-shop:
+                    filter: { kind: [optician, optical_shop, optical-shop] }
+                    draw:   { icons: { sprite: optical-shop } }
+                outdoor:
+                    filter: { kind: [outdoor] }
+                    draw:   { icons: { sprite: outdoor } }
+                performing-arts:
+                    filter: { kind: [theater, theatre, performing-arts] }
+                    draw:   { icons: { sprite: performing-arts } }
+                pet-store:
+                    filter: { kind: [pet, pet-store, pet-service, pet_store] }
+                    draw:   { icons: { sprite: pet-store } }
+                sports-pitch:
+                    filter: { kind: [grass, pitch] }
+                    draw:
+                        icons:
+                            sprite: function() { return feature.kind_detail; }
+                    baseball:
+                        filter: { kind_detail: baseball }
+                        draw: { icons: { sprite: baseball-field } }
+                    basketball:
+                        filter: { kind_detail: basketball }
+                        draw: { icons: { sprite: basketball-court } }
+                    football:
+                        filter: { kind_detail: football }
+                        draw: { icons: { sprite: football-stadium } }
+                    hockey:
+                        filter: { kind_detail: hockey-field }
+                        draw: { icons: { sprite: hockey-field } }
+                    soccer:
+                        filter: { kind_detail: soccer }
+                        draw: { icons: { sprite: soccer-field } }
+                    tennis:
+                        filter: { kind_detail: tennis }
+                        draw: { icons: { sprite: tennis } }
+                pharmacy:
+                    filter: { kind: [pharmacy, chemist] }
+                    draw:   { icons: { sprite: pharmacy } }
+                photography-lab:
+                    filter: { kind: [photo_studio, photography_lab, photographer] }
+                    draw:   { icons: { sprite: photography-lab } }
+                picnic-spot:
+                    filter: { kind: [picnic_site, picnic_spot, picnic-spot, picnic_table] }
+                    draw:   { icons: { sprite: picnic-spot } }
+                pool:
+                    filter: { kind: [pool, swimming_pool, water_park] }
+                    draw:   { icons: { sprite: pool } }
+                pool-hall:
+                    filter: { kind: [billiards, pool-hall] }
+                    draw:   { icons: { sprite: pool-hall } }
+                post-office:
+                    filter: { kind: [post_office, post-office] }
+                    draw:   { icons: { sprite: post-office } }
+                power-pylon:
+                    filter: { kind: [tower, power-pylon, pylon] }
+                    draw:   { icons: { sprite: power-pylon } }
+                real-estate:
+                    filter: { kind: [estate_agent, real_estate] }
+                    draw:   { icons: { sprite: real-estate } }
+                recreation-track:
+                    filter: { kind: [recreation_track] }
+                    draw:   { icons: { sprite: recreation-track } }
+                recycling-facility:
+                    filter: { kind: [recycling, recycling-facility] }
+                    draw:   { icons: { sprite: recycling-facility } }
+                rental-car:
+                    filter: { kind: [rental-car, car_rental, car_sharing] }
+                    draw:   { icons: { sprite: rental-car } }
+                rest-area:
+                    filter: { kind: [rest_area, rest-area] }
+                    draw:   { icons: { sprite: rest-area } }
+                restaurant:
+                    filter: { kind: [restaurant, deli] }
+                    draw:   { icons: { sprite: restaurant } }
+                ruin:
+                    filter: { kind: [ruins, archaeological_site] }
+                    draw:   { icons: { sprite: ruin } }
+                salon-barber:
+                    filter: { kind: [hairdresser, salon-barber, salon, beauty_salon] }
+                    draw:   { icons: { sprite: salon-barber } }
+                scuba-diving:
+                    filter: { kind: [scuba_diving,dive_centre] }
+                    draw:   { icons: { sprite: scuba-diving } }
+                ship-wreck:
+                    filter: { kind: [wreck] }
+                    draw:   { icons: { sprite: ship-wreck } }
+                shoe-store:
+                    filter: { kind: [shoes, shoe-store, shoe_store] }
+                    draw:   { icons: { sprite: shoe-store } }
+                slipway:
+                    filter: { kind: [slipway] }
+                    draw:   { icons: { sprite: slipway } }
+                smoke-shop:
+                    filter: { kind: [smoke_shop, tobacco] }
+                    draw:   { icons: { sprite: smoke-shop } }
+                spa-massage:
+                    filter: { kind: [spa, spa-massage, sauna, massage] }
+                    draw:   { icons: { sprite: spa-massage } }
+                # prefix with "a-" here to allow Tangram to sort the generic style 1st, allowing more specific religion tags to win later
+                a-spiritual-center:
+                    filter:
+                        all:
+                            - kind: [spiritual_center, spiritual-center, place_of_worship, wayside_chapel]
+                    draw:   { icons: { sprite: spiritual-center } }
+                church:
+                    filter: { kind: [spiritual_center, spiritual-center, place_of_worship, wayside_chapel], religion: christian }
+                    draw:   { icons: { sprite: church } }
+                synagogue:
+                    filter: { kind: [spiritual_center, spiritual-center, place_of_worship, wayside_chapel], religion: jewish }
+                    draw:   { icons: { sprite: synagogue } }
+                buddhist:
+                    filter: { kind: [spiritual_center, spiritual-center, place_of_worship, wayside_chapel], religion: buddhist }
+                    draw:   { icons: { sprite: buddhism } }
+                mosque:
+                    filter: { kind: [spiritual_center, spiritual-center, place_of_worship, wayside_chapel], religion: muslim }
+                    draw:   { icons: { sprite: mosque } }
+                sporting-goods-shop:
+                    filter: { kind: [sporting_goods, sporting-goods-shop, sports] }
+                    draw:   { icons: { sprite: sporting-goods-shop } }
+                stable:
+                    filter: { kind: [stable, horse_riding, horse] }
+                    draw:   { icons: { sprite: stable } }
+                storage-facility:
+                    filter: { kind: [storage, storage-facility] }
+                    draw:   { icons: { sprite: storage-facility } }
+                subway-entrance:
+                    filter: { kind: [subway_entrance] }
+                    draw:   { icons: { sprite: subway-entrance } }
+                summer-camp:
+                    filter: { kind: [summer_camp] }
+                    draw:   { icons: { sprite: summer-camp } }
+                tailor-shop:
+                    filter: { kind: [tailor, tailor-shop] }
+                    draw:   { icons: { sprite: tailor-shop } }
+                tattoo-parlor:
+                    filter: { kind: [tattoo, tattoo_parlor, tattoo-parlor] }
+                    draw:   { icons: { sprite: tattoo-parlor } }
+                telescope:
+                    filter: { kind: [telescope] }
+                    draw:   { icons: { sprite: telescope } }
+                theme-park:
+                    filter: { kind: [theme_park, theme-park, miniature_golf] }
+                    draw:   { icons: { sprite: theme-park } }
+                thrift-vintage-store:
+                    filter: { kind: [thrift, thrift-vintage-store, second_hand] }
+                    draw:   { icons: { sprite: thrift-vintage-store } }
+                toll-booth:
+                    filter: { kind: [toll_booth, checkpoint, border_control] }
+                    draw:   { icons: { sprite: toll-booth } }
+                toy-game-store:
+                    filter: { kind: [toys, toy-game-store, baby_goods] }
+                    draw:   { icons: { sprite: toy-game-store } }
+                toilets:
+                    filter: { kind: [toilets] }
+                    draw:   { icons: { sprite: toilets } }
+                trailhead:
+                    filter: { kind: [trailhead, hiking_trail] }
+                    draw:   { icons: { sprite: trailhead } }
+                # because: JAPAN
+                traffic-signal:
+                    filter: { kind: traffic_signals }
+                    draw:   { icons: { sprite: traffic-signal } }
+                veterinarian:
+                    filter: { kind: [pet_care, veterinarian, veterinary] }
+                    draw:   { icons: { sprite: veterinarian } }
+                video-game-store:
+                    filter: { kind: [video_games] }
+                    draw:   { icons: { sprite: video-game-store } }
+                video-store:
+                    filter: { kind: [video, video_store] }
+                    draw:   { icons: { sprite: video-store } }
+                view-point:
+                    filter: { kind: [viewpoint, view_point, view-point, vista] }
+                    draw:   { icons: { sprite: view-point } }
+                waterfall:
+                    filter: { kind: [waterfall] }
+                    draw:   { icons: { sprite: waterfall } }
+                waterpark:
+                    filter: { kind: [water_park] }
+                    draw:   { icons: { sprite: waterpark } }
+                well:
+                    filter: { kind: [well, water_well] }
+                    draw:   { icons: { sprite: well } }
+                wine-shop:
+                    filter: { kind: [wine, wine-shop] }
+                    draw:   { icons: { sprite: wine-shop } }
+                winery:
+                    filter: { kind: [winery, wine] }
+                    draw:   { icons: { sprite: winery } }
+                winter_sport:
+                    filter: { kind: [ski, ski_rental, ski_school, ski_jumping, skiing] }
+                    draw:   { icons: { sprite: ski-area } }
 
         airport-gate:
-            filter: { kind: aeroway_gate }
+            filter: { kind: gate, aeroway: gate }
             draw:
                 icons:
                     visible: false
                 text-blend-order:
                     visible: global.text_visible_airport_gate
+                    interactive: true
                     text_source: ref
-                    priority: 63
                     font:
                         fill: global.text_fill_exits
                         size: [[16,9px],[17,12px],[20,14px]]
+                        #stroke: { color: global.highway1, width: [[12,2px],[14,3px],[15,3px]] }
             later:
                 filter: { $zoom: { min: 19 } }
                 draw:
-                    icons:
-                        text:
-                            font:
-                                weight: 600
+                    text-blend-order:
+                        font:
+                            weight: 600
 
         highway-exit:
             filter: { kind: motorway_junction, $zoom: { min: 14 } }
@@ -5286,44 +6389,209 @@ layers:
                     visible: false
                 text-blend-order:
                     visible: global.text_visible_exits
+                    interactive: true
                     text_source: ref
-                    priority: 63
+                    priority: 1
                     font:
-                        family: Montserrat
                         fill: global.text_fill_exits
                         size: [[12,9px],[15,12px],[17,14px]]
                         stroke: { color: global.text_stroke, width: [[12,2px],[14,3px],[15,3px]] }
             later:
                 filter: { $zoom: { min: 16 } }
                 draw:
-                    icons:
-                        text:
-                            font:
-                                weight: 600
+                    text-blend-order:
+                        font:
+                            weight: 600
 
-    earth-labels:
-        data: { source: mapzen, layer: earth }
-        filter: { name: true }
+
+    water-area-labels:
+        data: { source: mapzen, layer: [water] }
+        visible: global.text_visible_water_labels
+        filter:
+            all:
+                - name: true
+                - $geometry: point
+                - not: { kind: [riverbank, dock, playa] }
+                - area: true
+            any:
+                # show labels for smaller landuse areas at higher zooms
+                - { $zoom: { min: 5 },  area: { min: 10000000000 } }
+                - { $zoom: { min: 6 },  area: { min: 5000000000 } }
+                - { $zoom: { min: 7 },  area: { min: 400000000 } }
+                - { $zoom: { min: 8 },  area: { min: 200000000 } }
+                - { $zoom: { min: 9 },  area: { min: 100000000 } }
+                - { $zoom: { min: 10 }, area: { min: 100000000 } }
+                - { $zoom: { min: 11 }, area: { min: 10000000 } }
+                - { $zoom: { min: 12 }, area: { min: 2000000 } }
+                - { $zoom: { min: 13 }, area: { min: 1000000 } }
+                - { $zoom: { min: 14 }, area: { min: 500000 } }
+                - { $zoom: { min: 15 }, area: { min: 100000 } }
+                - { $zoom: { min: 15 }, area: { min: 50000 } }
+                - { $zoom: { min: 16 }, area: { min: 20000 } }
+                - { $zoom: { min: 17 } }
+        default-label-text:
+            draw:
+                text-blend-order:
+                    text_source: global.ux_language_text_source
+                    font:
+                        fill: [0.314,0.591,0.640] #global.text_fill_water
+                        family: global.text_font_family
+                        style: italic
+                        weight: 400
+                        size: 12px
+                        # stroke: { color: [0.878,0.929,0.980], width: 2 }
+        lakes-z5:
+            filter: { $zoom: [5] }
+            draw:
+                text-blend-order: { font: { size: 9px } }
+        lakes-z6:
+            filter: { $zoom: [6] }
+            draw:
+                text-blend-order: { font: { size: 11px } }
+        lakes-z8:
+            filter: { $zoom: [8] }
+            draw:
+                text-blend-order: { font: { size: 12px } }
+
+    ocean-sea-labels:
+        data: { source: mapzen, layer: water }
+        visible: global.text_visible_water_labels
+        filter: { name: true, kind: [sea, ocean] }
+        draw:
+            text-blend-order:
+                text_source: global.ux_language_text_source
+                font:
+                    fill: [0.314,0.591,0.640] #global.text_fill_water
+                    family: global.text_font_family
+                    weight: 400
+                    size: 12px
+                    transform: uppercase
+        sea-early:
+            filter: { $zoom: [3], kind: sea }
+            draw: { text-blend-order: { visible: false } }
+        ocean-spacer:
+            filter: { kind: ocean }
+            ocean-spacer-z1-z4:
+                filter: { $zoom: { min: 1, max: 4 } }
+                draw:
+                    text-blend-order:
+                        text_source: global.ux_language_text_source_ocean
+                        text_wrap: false
+            ocean-spacer-z4-up:
+                filter: { $zoom: { min: 4 } }
+                draw:
+                    text-blend-order:
+                        text_source: global.ux_language_text_source_ocean
+                        text_wrap: false
+        ocean-labels-z1:
+            filter: { $zoom: [1] }
+            draw:
+                text-blend-order: { font: { size: 8px } }
+        ocean-labels-z2:
+            filter: { $zoom: [2] }
+            draw:
+                text-blend-order: { font: { size: 10px } }
+        ocean-labels-z3:
+            filter: { $zoom: [3] }
+            draw:
+                text-blend-order: { font: { size: 13px } }
+        ocean-labels-z4-up:
+            filter: { $zoom: { min: 4} }
+            draw:
+                text-blend-order: { font: { size: 16px } }
+
+        sea-spacer:
+            filter: { not: { kind: [ocean] }, $zoom: { min: 5 } }
+            draw:
+                text-blend-order:
+                    text_source: global.ux_language_text_source_sea
+                    text_wrap: false
+
+        sea-labels:
+            filter: { not: { kind: [ocean] } }
+            sea-labels-z4:
+                filter: { $zoom: [4] }
+                draw:
+                    text-blend-order: { font: { size: 9px } }
+            sea-labels-z5:
+                filter: { $zoom: [5] }
+                draw:
+                    text-blend-order: { font: { size: 10px } }
+            sea-labels-z6:
+                filter: { $zoom: [6] }
+                draw:
+                    text-blend-order: { font: { size: 11px } }
+            sea-labels-z7:
+                filter: { $zoom: [7] }
+                draw:
+                    text-blend-order: { font: { size: 12px } }
+            sea-labels-z8:
+                filter: { $zoom: { min: 8} }
+                draw:
+                    text-blend-order: { font: { size: 14px } }
+
+    playa-labels:
+        data: { source: mapzen, layer: [water] }
+        visible: global.text_visible_water_labels
+        filter:
+            all:
+                - name: true
+                - $geometry: point
+                - kind: playa
+                - area: true
+            any:
+                # show labels for smaller landuse areas at higher zooms
+                - { $zoom: { min: 7 },  area: { min: 1500000000 } }
+                - { $zoom: { min: 8 },  area: { min: 200000000 } }
+                - { $zoom: { min: 9 },  area: { min: 100000000 } }
+                - { $zoom: { min: 10 }, area: { min: 100000000 } }
+                - { $zoom: { min: 11 }, area: { min: 10000000 } }
+                - { $zoom: { min: 12 }, area: { min: 2000000 } }
+                - { $zoom: { min: 13 }, area: { min: 1000000 } }
+                - { $zoom: { min: 14 }, area: { min: 500000 } }
+                - { $zoom: { min: 15 }, area: { min: 100000 } }
+                - { $zoom: { min: 15 }, area: { min: 50000 } }
+                - { $zoom: { min: 16 }, area: { min: 20000 } }
+                - { $zoom: { min: 17 } }
         draw:
             text-blend-order:
                 text_source: global.ux_language_text_source
+                font:
+                    fill: grey
+                    family: global.text_font_family
+                    style: italic
+                    weight: 400
+                    size: 12px
+                    stroke: { color: global.text_stroke_water, width: 3 }
+        # debug only
+#        icons:
+#            size: [[13, 12px], [15, 18px]]
+#            interactive: true
+#            sprite: global.townspot_sprite
+
+    earth-labels:
+        data: { source: mapzen, layer: earth }
+        filter: { name: true }
         continent:
-            filter: { kind: [continent], $zoom: { max: 5 } }
+            filter: { name: true, kind: [continent], $zoom: {max: 5} }
             draw:
                 text-blend-order:
                     visible: global.text_visible_continent
-                    text_source: global.ux_language_text_source_continent_stacked_only
-                    text_wrap: false
                     font:
-                        family: Varela
-                        size: [[1,11px],[3,14px]]
-                        fill: [0.762,0.525,0.428]
+                        size: 14px
+                        style: italic
+                        fill: global.text_fill
+                        weight: 600
+                        # stroke: { color: global.text_stroke, width: 4 }
                         transform: uppercase
-            continent-spacer:
-                filter: { $zoom: { min: 2 } }
+        continent-spacer:
+            filter: { kind: continent }
+            continent-spacer-z1-z5:
+                filter: { $zoom: { min: 1, max: 5 } }
                 draw:
                     text-blend-order:
                         text_source: global.ux_language_text_source_continent
+                        text_wrap: false
         island:
             filter: { kind: [archipelago, island, islet] }
             draw:
@@ -5334,14 +6602,14 @@ layers:
                         size: 12px
                         style: italic
                         fill: global.text_fill
-                        weight: normal
+                        weight: 400
                         stroke: { color: global.text_stroke, width: 4 }
                         #transform: uppercase
 
     landuse:
         data: { source: mapzen }
         draw:
-            dots:
+            dots2:
                 order: global.feature_order
                 visible: false
             dots-rev:
@@ -5358,6 +6626,7 @@ layers:
 #                           return 1000;
 #                       }
 #                   }
+                interactive: true
                 #debug for polygon merging
                 #color: |
 #                   function() {
@@ -5396,13 +6665,13 @@ layers:
                 all:
                     - label_placement: true
                     - name: true
-                    - function() { return global.text_visible_landuse_generic; }
             draw:
                 text-blend-order:
                     text_source: global.ux_language_text_source
-                    interactive: global.sdk_interactive
+                    interactive: true
                     move_into_tile: true
                     priority: 100
+                    visible: global.text_visible_landuse_generic
                     font:
                         fill: '#666'
                         family: global.text_font_family
@@ -5410,7 +6679,25 @@ layers:
                         size: 11px
                         stroke: { color: global.text_stroke_address, width: 1 }
 
-        #TIER 1
+#        tier1:
+#            filter:
+#                any:
+#                    # limit show smaller landuse areas to higher zooms
+#                    - { $zoom: { min: 3 },  area: { min: 300000000 } }
+#                    - { $zoom: { min: 4 },  area: { min: 300000000 } }
+#                    - { $zoom: { min: 5 },  area: { min: 150000000 } }
+#                    - { $zoom: { min: 6 },  area: { min: 150000000 } }
+#                    - { $zoom: { min: 7 },  area: { min: 100000000 } }
+#                    - { $zoom: { min: 8 },  area: { min: 10000000 } }
+#                    - { $zoom: { min: 9 },  area: { min: 5000000 } }
+#                    - { $zoom: { min: 10 }, area: { min: 1000000 } }
+#                    - { $zoom: { min: 11 }, area: { min: 500000 } }
+#                    - { $zoom: { min: 12 }, area: { min: 500000 } }
+#                    - { $zoom: { min: 13 }, area: { min: 100000 } }
+#                    - { $zoom: { min: 14 }, area: { min: 50000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 20000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 2000 } }
+#                    - { $zoom: { min: 16 }, area: true }
         national_park:
             filter:
                 all:
@@ -5419,7 +6706,7 @@ layers:
                     - not: { operator: [ "United States Forest Service" ] }
                     - protect_class: ['2','3','5']
             draw:
-                dots:
+                dots2:
                     color: [[4,[0.655,0.800,0.796]],[8,[0.588,0.780,0.773]]]
                     # todo: what is this?
                     order: 18
@@ -5431,12 +6718,29 @@ layers:
                         - operator: [ "United States National Park Service" ]
                         - protect_class: ['2','3','5']
                 draw:
-                    dots:
+                    dots2:
                         color: [[4,[0.525,0.765,0.686]],[9,[0.416,0.737,0.631]]]
                         order: 19
                         visible: true
                         # color: [[4,[0.242,0.737,0.712]],[12,[0.224,0.682,0.659]]]
-        #TIER 2
+#        tier2:
+#            filter:
+#                any:
+#                    # limit show smaller landuse areas to higher zooms
+#                    - { $zoom: { min: 4 },  area: { min: 1000000000 } }
+#                    - { $zoom: { min: 5 },  area: { min: 1000000000 } }
+#                    - { $zoom: { min: 6 },  area: { min: 150000000 } }
+#                    - { $zoom: { min: 7 },  area: { min: 100000000 } }
+#                    - { $zoom: { min: 8 },  area: { min: 10000000 } }
+#                    - { $zoom: { min: 9 },  area: { min: 5000000 } }
+#                    - { $zoom: { min: 10 }, area: { min: 1000000 } }
+#                    - { $zoom: { min: 11 }, area: { min: 500000 } }
+#                    - { $zoom: { min: 12 }, area: { min: 250000 } }
+#                    - { $zoom: { min: 13 }, area: { min: 100000 } }
+#                    - { $zoom: { min: 14 }, area: { min: 50000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 20000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 2000 } }
+#                    - { $zoom: { min: 16 }, area: true }
         conservation:
             filter:
                 all:
@@ -5444,7 +6748,7 @@ layers:
                     - kind: [protected_area, nature_reserve, national_park]
                     - not: { protect_class: ['2','3','5'] }
             draw:
-                dots:
+                dots2:
                     # effectively the wilderness color
                     color: [[0,[0.442,0.960,0.865]],[11,[0.2,0.850,0.765]]] #red #[0.420,0.808,0.698]
                     visible: true
@@ -5457,7 +6761,7 @@ layers:
                     - protect_class: ['6']
                     - operator: ['United States Forest Service']
             draw:
-                dots:
+                dots2:
                     color: [0.442,0.960,0.865] #*green7
                     visible: true
 
@@ -5467,13 +6771,13 @@ layers:
                 kind: [farm, farmland]
                 $zoom: { min: 10}
             draw:
-                dots:
+                dots2:
                     color: [0.600,0.790,0.714]
                     visible: global.green4_v
         forest-landcover:
             filter: { kind: [forest, natural_forest, wood, natural_wood, natural_park], $zoom: { min: 10 }, not: { operator: "United States Forest Service" } }
             draw:
-                dots:
+                dots2:
                     color: [0.70,0.990,0.92] #[0.486,0.839,0.722]
                     visible: true
 
@@ -5487,10 +6791,15 @@ layers:
                     - not: { protect_class: ['2','3','5','6'] }
             # default for national forests and more?
             draw:
-                dots:
+                dots2:
                     # color: [[4,[0.655,0.800,0.796]],[11,[0.588,0.780,0.773]],[12,[0.242,0.737,0.712]],[14,[0.412,0.733,0.718]],[15,[0.635,0.792,0.788]]]
                     color: [[4,[0.655,0.800,0.796]],[11,[0.588,0.780,0.773]],[12,[0.635,0.792,0.788]]]
                     visible: true
+            #forest:
+#                    filter: { kind: forest }
+#                    draw:
+#                        dots2:
+#                            color: green
             national_park:
                 #filter: function() { return feature.name && (feature.name.indexOf('National Park') > -1); }
                 filter:
@@ -5498,64 +6807,88 @@ layers:
                         - kind: national_park
                         - not: [ protect_class: ['2','3','5','6'], operator: [ "United States National Park Service"] ]
                 draw:
-                    dots:
+                    dots2:
                         color: [[4,[0.525,0.765,0.686]],[9,[0.416,0.737,0.631]]]
         urban:
             filter: { kind: [urban, rural, residential] }
             visible: global.earth2_v
             draw:
-                dots:
+                dots2:
                     color: [[0, global.earth2],[9, global.earth2]]
                     visible: global.earth2_v
-        #TIER 3
+#        tier3:
+#            filter:
+#                any:
+#                    # limit show smaller landuse areas to higher zooms
+#                    - { $zoom: { min: 8 },  area: { min: 10000000 } }
+#                    - { $zoom: { min: 9 },  area: { min: 5000000 } }
+#                    - { $zoom: { min: 10 }, area: { min: 1000000 } }
+#                    - { $zoom: { min: 11 }, area: { min: 500000 } }
+#                    - { $zoom: { min: 12 }, area: { min: 500000 } }
+#                    - { $zoom: { min: 13 }, area: { min: 100000 } }
+#                    - { $zoom: { min: 14 }, area: { min: 50000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 20000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 2000 } }
+#                    - { $zoom: { min: 16 }, area: true }
         airport:
             filter:
                 kind: aerodrome
             draw:
-                dots:
+                dots2:
                     color: [0.805,0.805,0.825]
                     visible: true
         military:
             filter:
                 kind: military
             draw:
-                dots:
+                dots2:
                     color: [0.722,0.769,0.827]
                     visible: true
         university:
             filter:
                 kind: [university, college]
             draw:
-                dots:
+                dots2:
                     color: [0.827,0.753,0.682]
                     visible: true
-        #TIER 4
+#        tier4:
+#            filter:
+#                any:
+#                    # limit show smaller landuse areas to higher zooms
+#                    - { $zoom: { min: 10 }, area: { min: 1000000 } }
+#                    - { $zoom: { min: 11 }, area: { min: 500000 } }
+#                    - { $zoom: { min: 12 }, area: { min: 500000 } }
+#                    - { $zoom: { min: 13 }, area: { min: 100000 } }
+#                    - { $zoom: { min: 14 }, area: { min: 50000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 20000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 2000 } }
+#                    - { $zoom: { min: 16 }, area: true }
         cemetery:
             filter:
                 kind: cemetery
             draw:
-                dots:
+                dots2:
                     color: global.green2
                     visible: true
         commercial:
             filter:
                 kind: commercial
             draw:
-                dots:
+                dots2:
                     color: [0.855,0.748,0.667]
                     visible: global.grey1_v
         golf_course:
             filter:
                 kind: golf_course
             draw:
-                dots:
+                dots2:
                     color: [0.353,0.812,0.545]
                     visible: true
         hospital:
             filter:
                 kind: hospital
             draw:
-                dots:
+                dots2:
                     color: [0.843,0.624,0.647]
                     visible: true
         industrial:
@@ -5568,7 +6901,7 @@ layers:
         power:
             filter: { kind: [plant, generator, substation] }
             draw:
-                dots:
+                dots2:
                     color: [0.679,0.679,0.679]
                     visible: true
         railway:
@@ -5582,56 +6915,75 @@ layers:
             filter:
                 kind: sports_centre
             draw:
-                dots:
+                dots2:
                     color: global.green10
         recreation_ground:
             filter:
                 kind: recreation_ground
             draw:
-                dots:
+                dots2:
                     color: global.green1
                     visible: true
         retail:
             filter:
                 kind: retail
             draw:
-                dots:
+                dots2:
                     color: [0.955,0.752,0.650]
                     visible: global.grey1_v
         stadium:
             filter:
                 kind: stadium
             draw:
-                dots:
+                dots2:
                     color: [0.624,0.690,0.761]
                     visible: true
         zoo:
             filter:
                 kind: [zoo, wildlife_park]
             draw:
-                dots:
+                dots2:
                     color: [0.498,1.000,0.851]
                     visible: true
         winter_sports:
             filter:
                 kind: winter_sports
             draw:
-                dots:
+                dots2:
                     color: global.grey8
                     visible: global.grey8_v
         man-made:
             filter: { kind: [pier,wastewater_plant,works,bridge,tower,breakwater,water_works,groyne,dike,cutline] }
             draw:
-                dots:
+                dots2:
                     color: [0.690,0.690,0.690]
                     visible: true
             pier:
                 filter: { kind: [pier,bridge,breakwater,groyne,dike,cutline] }
                 draw:
-                    dots:
+                    dots2:
                         color: [0.679,0.679,0.679]
                         visible: true
-        #TIER 5
+#        tier5:
+#            filter:
+#                any:
+#                    # limit show smaller landuse areas to higher zooms
+#                    - { $zoom: { min: 10 }, area: { min: 1000000 } }
+#                    - { $zoom: { min: 11 }, area: { min: 400000 } }
+#                    - { $zoom: { min: 12 }, area: { min: 200000 } }
+#                    - { $zoom: { min: 13 }, area: { min: 50000 } }
+#                    - { $zoom: { min: 14 }, area: { min: 20000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 10000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 2000 } }
+#                    - { $zoom: { min: 16 } }
+#            all:
+#                - kind:
+#                    - theme_park
+#                    - resort
+#                    - aquarium
+#                    - winery
+#                    - maze
+#                    - beach
         tourism-related:
             filter:
                 kind:
@@ -5641,92 +6993,113 @@ layers:
                     - winery
                     - maze
             draw:
-                dots:
+                dots2:
                     color: global.grey10
                     visible: true
         beach:
            filter:
                kind: beach
            draw:
-               dots:
+               dots2:
                    color: [0.780,0.740,0.538]
                    visible: true
-        #TIER 6
-        garden:
-            filter:
-                kind: [garden, allotments]
-            draw:
-                dots:
-                    color: [0.604,0.973,0.722]
-                    visible: true
-        parking:
+        #tier6-early:
+#            filter:
+#                all:
+#                    - kind: [garden, allotments, parking, pedestrian, common, pitch, place_of_worship, playground, school]
+#                any:
+#                    # limit show smaller landuse areas to higher zooms
+#                    - { $zoom: { max: 13 } }
+##                    - { $zoom: [12], area: { max: 50000 } }
+#            draw:
+#                dots2:
+#                    visible: false
+        tier6:
             filter:
                 all:
-                    - kind: parking
-                    - $zoom: { min: 14 }
-                any:
-                    - { $zoom: { min: 14 }, area: { min: 10000 } }
-                    - { $zoom: { min: 15 }, area: { min: 5000 } }
-            draw:
-                dots:
-                    color: [0.765,0.765,0.765]
-                    visible: global.grey1_v
-            early:
-                filter: { $zoom: { max: 15 } }
+                    - kind: [garden, allotments, parking, pedestrian, common, pitch, place_of_worship, playground, school]
+                #any:
+#                    # limit show smaller landuse areas to higher zooms
+#                    #- { $zoom: { min: 12 }, area: { min: 500000 } }
+#                    - { $zoom: { min: 13 }, area: { min: 100000 } }
+#                    - { $zoom: { min: 14 }, area: { min: 50000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 20000 } }
+#                    - { $zoom: { min: 15 }, area: { min: 2000 } }
+#                    - { $zoom: { min: 16 }, area: true }
+            garden:
+                filter:
+                    kind: [garden, allotments]
                 draw:
-                    dots:
-                        color: global.grey1_e
+                    dots2:
+                        color: [0.604,0.973,0.722]
                         visible: true
-        pedestrian:
-            filter:
-                kind: [pedestrian,common]
-            draw:
-                dots:
-                    color: [0.740,0.740,0.740]
-                    visible: global.grey1_v
-            green-stuff:
+            parking:
                 filter:
-                    surface: [grass]
+                    all:
+                        - kind: parking
+                        - $zoom: { min: 14 }
+                    any:
+                        - { $zoom: { min: 14 }, area: { min: 10000 } }
+                        - { $zoom: { min: 15 }, area: { min: 5000 } }
                 draw:
-                    dots:
-                        color: [0.584,0.843,0.792]
-        # glacier:
-        #     filter:
-        #         kind: glacier
-        #     draw:
-        #         terrain:
-        #             color: [0.890,0.970,1.000]
-        #             # color: [0.975,0.975,0.828]
-        #             visible: true
-
-        pitch:
-            filter: { kind: pitch }
-            draw:
-                dots:
-                    color: [0.490,0.812,0.631]
-                    visible: true
-        place_of_worship:
-            filter:
-                kind: place_of_worship
-            draw:
-                dots:
-                    color: [0.910,0.972,1.000]
-                    visible: global.grey1_v
-        playground:
-            filter:
-                kind: playground
-            draw:
-                dots-rev:
-                    color: [0.584,0.843,0.792]
-                    visible: true
-        school:
-            filter:
-                kind: school
-            draw:
-                dots:
-                    color: [0.749,0.722,0.694]
-                    visible: true
+                    dots2:
+                        color: [0.765,0.765,0.765]
+                        visible: global.grey1_v
+                early:
+                    filter: { $zoom: { max: 15 } }
+                    draw:
+                        dots2:
+                            color: global.grey1_e
+                            visible: true
+            pedestrian:
+                filter:
+                    kind: [pedestrian,common]
+                draw:
+                    dots2:
+                        color: [0.740,0.740,0.740]
+                        visible: global.grey1_v
+                green-stuff:
+                    filter:
+                        surface: [grass]
+                    draw:
+                        dots2:
+                            color: [0.584,0.843,0.792]
+            # glacier:
+            #     filter:
+            #         kind: glacier
+            #     draw:
+            #         terrain:
+            #             color: [0.890,0.970,1.000]
+            #             # color: [0.975,0.975,0.828]
+            #             visible: true
 
+            pitch:
+                filter: { kind: pitch }
+                draw:
+                    dots2:
+                        color: [0.490,0.812,0.631]
+                        visible: true
+            place_of_worship:
+                filter:
+                    kind: place_of_worship
+                draw:
+                    dots2:
+                        color: [0.910,0.972,1.000]
+                        visible: global.grey1_v
+            playground:
+                filter:
+                    kind: playground
+                draw:
+                    dots-rev:
+                        color: [0.584,0.843,0.792]
+                        visible: true
+            school:
+                filter:
+                    kind: school
+                draw:
+                    dots2:
+                        color: [0.749,0.722,0.694]
+                        visible: true
         minor-landuse:
             filter:
                 kind:
@@ -5735,7 +7108,7 @@ layers:
                     - wilderness_hut
                     - hanami
             draw:
-                dots:
+                dots2:
                     color: [0.765,0.765,0.765]
                     visible: true
 
@@ -5761,100 +7134,96 @@ layers:
                     color: [0.602,0.860,0.722]
                     width: [[16,0.5px],[17,1px],[19,1m]]
 
-        landuse-not-filtered:
-            # runways and taxiways are also in the roads layer as lines
-            # these ones are probably duplicate features, but have AREA (a good thing)
+    landuse-not-filtered:
+        data: { source: mapzen, layer: landuse }
+        # runways and taxiways are also in the roads layer as lines
+        # these ones are probably duplicate features, but have AREA (a good thing)
+        filter:
+            kind:
+                - runway
+                - apron
+                - beach
+                - roller_coaster
+                - amusement_ride
+                - summer_toboggan
+                - trail_riding_station
+                - water_slide
+                - carousel
+                - animal
+                - enclosure
+                - petting_zoo
+                - aviary
+        draw:
+            dots2:
+                order: global.feature_order
+                visible: false
+            dots-rev:
+                order: global.feature_order
+                visible: false
+            polygons:
+                visible: false
+                order: global.feature_order
+        runway:
+            filter:
+                kind: runway
+            draw:
+                polygons:
+                    visible: true
+                    color: [[10,[0.4,0.4,0.4]],[11,[0.50,0.50,0.50]],[12,[0.7,0.7,0.7]],[13,[0.75,0.75,0.75]],[14,[0.95,0.95,0.95]]]
+        apron:
+            filter:
+                kind: apron
+                $zoom: { min: 15}
+            draw:
+                dots-rev:
+                    visible: true
+                    color: [0.820,0.820,0.820]
+        minor-amusement-park-landuse:
             filter:
                 kind:
-                    - runway
-                    - apron
-                    - beach
                     - roller_coaster
                     - amusement_ride
                     - summer_toboggan
                     - trail_riding_station
                     - water_slide
                     - carousel
+            draw:
+                dots2:
+                    color: global.grey12
+                    visible: true
+        minor-zoo-landuse:
+            filter:
+                kind:
                     - animal
                     - enclosure
                     - petting_zoo
                     - aviary
             draw:
-                dots:
-                    order: global.feature_order
-                    visible: false
-                dots-rev:
-                    order: global.feature_order
-                    visible: false
-                polygons:
-                    visible: false
-                    order: global.feature_order
-            runway:
-                filter:
-                    kind: runway
-                draw:
-                    polygons:
-                        visible: true
-                        color: [[10,[0.4,0.4,0.4]],[11,[0.50,0.50,0.50]],[12,[0.7,0.7,0.7]],[13,[0.75,0.75,0.75]],[14,[0.95,0.95,0.95]]]
-                early:
-                    filter: { $zoom: [9] }
-                    draw:
-                        polygons:
-                            visible: false
-            apron:
-                filter:
-                    kind: apron
-                    $zoom: { min: 15}
-                draw:
-                    dots-rev:
-                        visible: true
-                        color: [0.820,0.820,0.820]
-            minor-amusement-park-landuse:
-                filter:
-                    kind:
-                        - roller_coaster
-                        - amusement_ride
-                        - summer_toboggan
-                        - trail_riding_station
-                        - water_slide
-                        - carousel
-                draw:
-                    dots:
-                        color: global.grey12
-                        visible: true
-            minor-zoo-landuse:
-                filter:
-                    kind:
-                        - animal
-                        - enclosure
-                        - petting_zoo
-                        - aviary
-                draw:
-                    dots:
-                        color: global.green11
-                        visible: true
-
-        landuse_urban_area-early:
-            filter:
-                # This is from Natural Earth and only shows up from zoom(0,9)
-                kind: urban_area
-            draw:
-                dots:
-                    visible: global.earth2_ev
-                    order: global.feature_order
-                    color: [[4,[0.965,0.600,0.882]],[6,[0.965,0.600,0.882]],[7,[0.882,0.639,0.827]],[8,[0.757,0.729,0.753]]]
+                dots2:
+                    color: global.green11
+                    visible: true
+    landuse_urban_area-early:
+        data: { source: mapzen, layer: landuse }
+        filter:
+            # This is from Natural Earth and only shows up from zoom(0,9)
+            kind: [urban_area, 'urban area']
+        draw:
+            dots2:
+                visible: global.earth2_ev
+                order: global.feature_order
+                color: [[4,[0.965,0.600,0.882]],[6,[0.965,0.600,0.882]],[7,[0.882,0.639,0.827]],[8,[0.757,0.729,0.753]]]
 
     transit-overlay-rail-lines:
         data: { source: mapzen, layer: transit }
         filter:
-            all:
-                - not: { kind: [platform, railway] }
-                - function() { return global.sdk_transit_overlay; }
+            not: { kind: [platform, railway] }
         draw:
             lines:
                 order: 499
+                visible: global.sdk_transit_overlay
                 color: purple
                 width: [[5,1.5px],[6,2px],[11,3px],[18,4px]]
+                interactive: true
                 outline:
                     color: [1.,1.,1.,.8]
                     width: [[7,0px],[8,0.25px],[9,0.5px],[12,1.0px],[13,1.75px],[14,2px]]
@@ -5934,99 +7303,36 @@ layers:
                 draw:
                     lines:
                         order: 504
+        labels-transit-lines-early:
+            filter: { $zoom: [13,14], ref: true }
+            draw:
+                text:
+                    visible: global.sdk_transit_overlay
+                    priority: 20
+                    text_source: function() { if( feature.ref.length < 4 ) { return feature.ref; } else { return ''; } }
+                    font:
+                        fill: black
+                        size: 12px
+                        weight: bold
+                        stroke: { color: white, width: 2 }
         labels-transit-lines:
-            filter:
-                all:
-                    - function() { return global.sdk_transit_overlay; }
-                    - all:
-                        - $zoom: { min: 13 }
-                        - ref: true
+            filter: { $zoom: { min: 15 } }
             draw:
-                icons:
+                text:
+                    visible: global.sdk_transit_overlay
                     priority: 20
-                    # you need to match any custom shield to the vector tile `network` values
-                    sprite: function() { return ('sdk_shield-' + feature.ref.length + 'char'); }
-                    sprite_default: sdk_shield_5char
-                    color: function() { if ( feature.kind === 'train') { return 'purple' } else { return feature.colour || 'purple'; } }
-                    # Size is specified below, and limited to 5 char in another filter
-                    repeat_group: shields
-                    repeat_distance: [[8,90px],[10,40px],[13,30px]]
-                    placement: midpoint
-                    placement_min_length_ratio:
-                        - [8, 0.1]
-                        - [9, 0.25]
-                        - [10, 0.25]
-                        - [11, 0.15]
-                        - [12, 1]
-                        - [13, 1.50]
-                        - [14, 2.0]
-                    cull_from_tile: true
-#                    visible: false
-                    text:
-                        offset: [0px, -0.5px]
-                        repeat_distance: 200px
-                        anchor: center
-                        text_source: function() { if( feature.ref.length < 6 ) { return feature.ref; } else { return ''; } }
-                        font:
-                            family: Montserrat
-                            fill: function() { if(feature.colour == 'yellow') { return '#555'; } else { return 'white'; } }
-                            style: bold
-                            size: [[7,7px],[12,8px],[16,11px]]
-
-            width_1char:
-                filter: function() { return (feature.ref.length === 1); }
-                draw:
-                    icons:
-                        size: [[6,[16px,16px]],[13,[18px,18px]],[16,[21px,21px]]]
-            width_2char:
-                filter: function() { return (feature.ref.length === 2); }
-                draw:
-                    icons:
-                        size: [[6,[21px,16px]],[13,[24px,18px]],[16,[28px,21px]]]
-            width_3char:
-                filter: function() { return (feature.ref.length === 3); }
-                draw:
-                    icons:
-                        size: [[6,[27px,16px]],[13,[31px,18px]],[16,[36px,21px]]]
-            width_4char:
-                filter: function() { return (feature.ref.length === 4); }
-                draw:
-                    icons:
-                        size: [[6,[32px,16px]],[13,[36px,18px]],[16,[41px,21px]]]
-                # London sucks
-                early:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        icons:
-                            visible: false
-            width_5char:
-                filter: function() { return (feature.ref.length === 5); }
-                draw:
-                    icons:
-                        size: [[6,[37px,16px]],[13,[41px,18px]],[16,[48px,21px]]]
-                # London sucks
-                early:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        icons:
-                            visible: false
-            # this is kinda a hack
-            width_longggggg:
-                filter: function() { return (feature.ref.length > 5); }
-                draw:
-                    icons:
-                        visible: false
-
-        z19-show-long-route-name:
-                filter:
-                    all:
-                        - function() { return global.sdk_transit_overlay; }
-                        - $zoom: { min: 19 }
+                    text_source: ref
+                    font:
+                        fill: black
+                        size: 14px
+                        weight: bold
+                        stroke: { color: white, width: 2 }
+            z19-show-long-route-name:
+                filter: { $zoom: { min: 19 } }
                 draw:
                     text:
+                        text_source: function() { return feature.route_name || feature.ref; }
                         font:
-                            fill: black
-                            style: italic
                             stroke: { color: white, width: 3px }
 
 #    transit-bus-roads:
@@ -6045,7 +7351,7 @@ layers:
 #                    order: 487
 
     transit-overlay-station-labels:
-        data: { source: mapzen, layer: pois }
+        data: { source: mapzen, layer: [pois] }
         filter:
             kind: [station, tram_stop, bus_station, subway_entrance, halt, stop, platform, bus_stop, stop_position ]
             any:
@@ -6059,18 +7365,19 @@ layers:
             icons:
                 visible: global.sdk_transit_overlay
                 size: [[13, 12px], [16, 16px], [19, 20px]]
-                interactive: global.sdk_interactive
+                interactive: true
                 priority: 15
                 text:
                     buffer: 4px
                     move_into_tile: false # preserves text alignment w/icons in JS
                     #anchor: bottom
                     #offset: [[13, [0, 6px]], [16, [0, 8px]], [19, [0, 10px]]] # offset tracks alongside icon size (half icon height)
-                    interactive: global.sdk_interactive
+                    interactive: true
                     priority: 16
                     font:
+                        weight: 500
                         fill: black
-                        weight: normal
+                        weight: 400
                         size: 11px
                         stroke: { color: white, width: 3 }
         poi_labels-z14:
@@ -6089,7 +7396,7 @@ layers:
             filter: { kind: [station, train-station, train_station] } #, $zoom: { min: 13 }
             draw:
                 icons:
-                    sprite: train_station
+                    sprite: train-station
                     size: [[13, 12px], [14, 14px], [15, 16px], [17, 20px]]
                     priority: 11
                     text:
@@ -6152,7 +7459,7 @@ layers:
                 icons:
                     size: [[15, 8px], [16, 18px]]
                     visible: global.sdk_transit_overlay
-                    sprite: light_rail
+                    sprite: light-rail
                     text:
                         visible: false
         platform-early:
@@ -6170,7 +7477,7 @@ layers:
                 icons:
                     size: [[13, 0px], [14, 7px], [15, 8px]]
                     visible: global.sdk_transit_overlay
-                    sprite: light_rail
+                    sprite: light-rail
                     text:
                         visible: false
         tram-stop:
@@ -6178,7 +7485,7 @@ layers:
             draw:
                 icons:
                     size: [[16, 12px], [17, 14px], [18, 18px]]
-                    sprite: light_rail
+                    sprite: light-rail
                     #text:
                         #offset: [[13, [0, 6px]], [16, [0, 9px]]]
         bus-like-labels:
@@ -6187,9 +7494,9 @@ layers:
             draw:
                 icons:
                     size: [[13, 8px], [16, 10px], [17, 12px], [18, 18px]]
-                    sprite: bus_station
+                    sprite: bus-station
                     text:
-                        interactive: global.sdk_interactive
+                        interactive: true
                         font:
                             fill: black
                             size: 12px
@@ -6201,10 +7508,10 @@ layers:
             draw:
                 icons:
                     size: [[13, 12px], [16, 18px]]
-                    sprite: bus_station
+                    sprite: bus-station
                     priority: 17
                     text:
-                        interactive: global.sdk_interactive
+                        interactive: true
                         priority: 18
                         font:
                             fill: black
@@ -6224,19 +7531,20 @@ layers:
                 kind: [subway_entrance]
             draw:
                 icons:
-                    sprite: subway_entrance
+                    sprite: subway-entrance
                     size: [[17, 12px], [19, 14px]]
                     priority: 19
                     text:
                         #offset: [[17, [0, 6px]], [19, [0, 7px]]] # offset tracks alongside icon size (half icon height)
                         priority: 20
-                        interactive: global.sdk_interactive
+                        interactive: true
                         text_source: function() { if( feature.ref || feature.name ) { if( feature.ref && feature.name ) { return '[' + feature.ref + ']\n' + feature.name; } else { return feature.name; } } else { return "Entrance"; } }
                         font:
                             fill: black
                             size: 12px
                             stroke: { color: white, width: 4 }
 
+
 #    transit-platforms:
 #        data: { source: mapzen, layer: transit }
 #        filter: { kind: platform, $zoom: { min: 15 }, $geometry: [polygon,line] }
@@ -6261,3 +7569,11 @@ layers:
 #                        width: [[15,0px],[16,0.5px],[17,1px],[19,2px]]
 #                lines:
 #                    visible: false
+
+    debug:
+        data: { source: mapzen }
+        draw:
+            flat_lines:
+                width: 2px
+                order: 1000
+                color: '#ff0000'
diff --git a/scenes/bubble-wrap/images/bubble-wrap@2x.png b/scenes/bubble-wrap/images/bubble-wrap@2x.png
deleted file mode 100644 (file)
index e151b93..0000000
Binary files a/scenes/bubble-wrap/images/bubble-wrap@2x.png and /dev/null differ
diff --git a/scenes/bubble-wrap/images/poi_icons_18@2x.png b/scenes/bubble-wrap/images/poi_icons_18@2x.png
new file mode 100644 (file)
index 0000000..fb7df40
Binary files /dev/null and b/scenes/bubble-wrap/images/poi_icons_18@2x.png differ
diff --git a/scenes/walkabout-style/images/draw-test10.jpg b/scenes/walkabout-style/images/draw-test10.jpg
deleted file mode 100644 (file)
index 46f6309..0000000
Binary files a/scenes/walkabout-style/images/draw-test10.jpg and /dev/null differ
diff --git a/scenes/walkabout-style/images/draw-test8.jpg b/scenes/walkabout-style/images/draw-test8.jpg
new file mode 100644 (file)
index 0000000..0690ad3
Binary files /dev/null and b/scenes/walkabout-style/images/draw-test8.jpg differ
diff --git a/scenes/walkabout-style/images/draw-test9.jpg b/scenes/walkabout-style/images/draw-test9.jpg
new file mode 100644 (file)
index 0000000..689e3cc
Binary files /dev/null and b/scenes/walkabout-style/images/draw-test9.jpg differ
diff --git a/scenes/walkabout-style/images/poi_icons_18@2x.png b/scenes/walkabout-style/images/poi_icons_18@2x.png
new file mode 100644 (file)
index 0000000..dde70c0
Binary files /dev/null and b/scenes/walkabout-style/images/poi_icons_18@2x.png differ
diff --git a/scenes/walkabout-style/images/relief-shading-environment-map.jpg b/scenes/walkabout-style/images/relief-shading-environment-map.jpg
new file mode 100644 (file)
index 0000000..a98c5fb
Binary files /dev/null and b/scenes/walkabout-style/images/relief-shading-environment-map.jpg differ
index ee6a536..625e0a9 100644 (file)
 #
 
 global:
-    # Sign up for a Mapzen API key to enjoy higher rate limits
-    # https://mapzen.com/documentation/overview/#developer-accounts-and-api-keys
-    sdk_mapzen_api_key: ''     # set this value to your Mapzen API key
-
     #ux/ui
     ux_language: false             # l10n language code, trusting OSM in v0.10 tiles, fixed in v1.0 tiles
     ux_language_fallback: false    # l10n language code, trusting OSM in v0.10 tiles, fixed in v1.0 tiles
@@ -204,220 +200,220 @@ global:
     sdk_shield_text_color: white
     #
     # enable interactivity for key features
-    interactive: false
+    interactive: true
     #
     # default order for basemap features
     feature_order: function() { return feature.sort_rank; }
-    sdk_building_extrude: true              # building extrusion toggle
+    building_extrude: true
     #
-    #labels-global:
-    text_visible_continent:         true
-    text_visible_island:            true
-    text_visible_admin:             true
-    text_visible_populated_places:  true
-    icon_visible_populated_places:  true
-    text_visible_neighbourhoods:    true
-    text_visible_neighbourhoods_e:  true
-    text_visible_building:          true           # false for default
-    text_visible_address:           true           # false for default
-    text_visible_water_labels:      true
-    label_visible_landuse_green:    true            #this needs work
-    icon_visible_landuse_green:     true            #this needs work
-    icon_size_green:                [[13, '14px'], [16, '18px'], [18, '19px']]    # 0px for no, default, more  [[13, '14px'], [16, '18px'], [18, '19px']]
-    icon_size_green_l:              [[14, '24px'], [16, '32px']]                  # 0px for no, default, more  [[14, '24px'], [16, '32px']]
-    text_visible_landuse_green:     true
-    label_visible_poi_landuse:      true
-    icon_visible_poi_landuse:       true           #false for default
-    text_visible_poi_landuse:       true           #false for default
-    label_visible_poi_landuse_e:    true
-    icon_visible_poi_landuse_e:     true           #false for default
-    text_visible_poi_landuse_e:     true
-    text_visible_landuse_generic:   true
-    label_visible_station:          true           #false for default
-    icon_visible_station:           true           #false for default
-    text_visible_station:           true           #false for default
-    text_visible_highway:           true
-    text_visible_highway_e:         true           #false for default
-    text_visible_trunk_primary:     true
-    text_visible_trunk_primary_e2:  true           #false for default
-    text_visible_trunk_primary_e:   true           #false for default
-    text_visible_secondary:         true
-    text_visible_secondary_e:       true           #false for default
-    text_visible_tertiary:          true
-    text_visible_tertiary_e:        true           #false for default
-    text_visible_minor_road:        true
-    text_visible_minor_road_e:      true
-    text_visible_service_road:      true
-    text_visible_path:              true
-    text_visible_piste:             true
-    text_visible_steps:             true
-    text_visible_aerialway:         true
-    sdk_road_shields:               true
-    text_visible_exits:             true
-    text_visible_exits_e:           true           #false for default
-    text_visible_airport_gate:      true
-
-    #cameras:
-    camera_settings: { type: isometric, axis: [-.2, .2] }
-
-    #lights:
-    light_settings: { type: directional, direction: [1, 1, -.9], diffuse: 0.5, ambient: 0.85 }
-
-    #roads:
-    highway1:                   [1.00,1.00,1.00]
-    highway_link1:              [0.00, 0.00, 0.00]
-    highway_casing1:            [0.894,0.906,0.914]
-    highway_tunnel1:            [0.930,0.930,0.930]
-    highway_tunnel_casing1:     [0.894,0.906,0.914]
-    highway_link_tunnel_casing1: [0.350,0.350,0.350]
-    ferry1:                     [0.410,0.750,0.833]
-    rail1:                      '#999'
-    rail1_e:                    '#bbb'
-    rail2:                      '#777'             # less important rail (service, sidings)
-    major_road1:                [1.0, 1.0, 1.0]
-    major_road1b:               [0.935, 0.935, 0.935]
-    major_road1c:               white    #15%
-    major_road2:                [0.935, 0.935, 0.935]
-    major_road2a:               [0.935, 0.935, 0.935]
-    major_road2b:               [0.935, 0.935, 0.935]
-    major_road3:                [0.935, 0.935, 0.935]
-    major_road4:                [0.00, 0.00, 0.00]
-    major_road5:                white
-    major_casing1:              [0.40, 0.40, 0.40]        # same as highway_casing1
-    major_casing2:              [0.40, 0.40, 0.40]        # zoomed out
-    major_tunnel1:              [0.930,0.930,0.930]
-    major_tunnel_casing1:       [0.695,0.739,0.790]
-    major_route1:               [0.0, 0.0, 0.0]
-    major_route2:               [0.2, 0.2, 0.2]           # zoomed out
-    minor_route:                [0.97, 0.97, 0.97]        # same as major_route
-    minor_road1:                [0.935, 0.935, 0.935]     # natural earth
-    minor_road2:                [1.00,1.00,1.00]     # natural earth, same as major_road2
-    minor_road3:                [0.935, 0.935, 0.935]
-    minor_road4:                [0.935, 0.935, 0.935]     # zoomed out
-    minor_road5:                [0.935, 0.935, 0.935]     # zoomed out, again
-    minor_casing1:              white                     # same as highway_casing1
-    minor_casing2:              white                     # zoomed out
-    minor_tunnel1:              [0.929,0.929,0.929]
-    minor_tunnel_casing1:       [1.00, 1.00, 1.00]
-    service_road1:              [0.935, 0.935, 0.935]
-    service_road2:              white
-    service_road_casing1:       [0.40, 0.40, 0.40]
-    service_road_casing2:       white
-    path1:                      [0.97, 0.97, 0.97]
-    path2:                      [0.97, 0.97, 0.97]        # zoomed out
-    path_casing1:               [0.40, 0.40, 0.40]
-    path_bridge_casing1:        [0.40, 0.40, 0.40]
-    path_bridge_casing2:        [0.40, 0.40, 0.40]        # zoomed out
-    path_steps1:                red
-    path_steps1_b:              '#ccc'
-    piste_easy:                 [0.367,0.750,0.622]
-    piste_intermediate:         [0.420,0.678,0.863]
-    piste_advanced:             [0.450,0.450,0.450]
-    piste_expert:               [0.450,0.450,0.450]
-
-    #boundaries:
-    country_boundary:           [1.00,1.00,1.00]
-    region_boundary:            [1.00,1.00,1.00]
-    subregion_boundary:         [1.00,1.00,1.00]
-    city_wall:                  [0.682,0.682,0.682]
-    retaining_wall:             [0.827,0.808,0.780]
-    snow_fence:                 [0.827,0.808,0.780]
-    fence:                      [0.827,0.808,0.780]
-    dam:                        [0.827,0.808,0.780]
-
-    #areas:
-    scene1:      white                    # map background
-    water1:      [0.870, 0.870, 0.870]    # water wave
-    water2:      [0.760, 0.760, 0.760]    # water wave
-    water3:      [0.5, 0.5, 0.5]          # playa texture
-    water1_o:    '#fff'                   # water stroke (ocean coastline)
-    water2_o:    '#d1d1d1'                # water stroke 2 (streams, lake outlines)
-    earth1:      white                    # land color
-    earth2:      '#e9e4e0'                # urban
-    earth2_v:    false                    # urban
-    green1:      [0.50,0.50,0.50]         # park
-    green1_r:    '#bbbbbb'                # park roads
-    green1_b:    [.65, .65, .65]          # park buildings
-    green1_bo:   [.8, .8, .8]             # park building outlines
-    green2:      [0.90,0.90,0.90]         # cemetery
-    green3:      '#9a9a9a'                # golf course
-    green4:      [0.90,0.90,0.90]         # farm faint
-    green4_v:    false                    # farm faint
-    green5:      [0.75,0.75,0.75]         # farm
-    green6:      [0.40,0.40,0.40]         # nature reserve
-    green7:      [0.85,0.85,0.85]         # forest
-    green8:      [0.80,0.80,0.80]         # conservation
-    green9:      [0.85,0.85,0.85]         # forest (landcover)
-    green9_e:    [0.90,0.90,0.90]         # forest (landcover) early
-    green9_v:    true                     # forest (landcover) visibility
-    green10:     [0.85,0.85,0.85]         # sports_centre
-    green11:     [0.85,0.85,0.85]         # minor zoo related AOIs
-    green11_o:   [0.85,0.85,0.85]         # minor zoo related AOIs outline
-    orange1:     '#aaaaaa'                # stadium
-    orange2:     [0.40,0.40,0.40]         # pitch (play field)
-    brown1:      '#7b7b7b'                # university
-    brown1_r:    '#bbbbbb'                # university roads
-    brown1_b:    [.65, .65, .65]          # university buildings
-    brown1_bo:   [.8, .8, .8]             # university building outlines
-    brown2:      '#aaaaaa'                # school
-    brown3:      [0.40,0.40,0.40]         # playground
-    red1:        '#a2a2a2'                # hospital
-    red1_r:      '#bbbbbb'                # hospital roads
-    red1_b:      [.65, .65, .65]          # hospital buildings
-    red1_bo:     [.8, .8, .8]             # hospital building outlines
-    gray-all:    [0.935,0.960,0.970]      # default gray for landuse outdoor style
-    grey1:       '#cccccc'                # pedestrian, retail, airport apron, parking, church
-    grey1_e:     '#dad6d4'                # pedestrian, retail, airport apron, parking, church early zoom 14
-    grey1_v:     true                     # pedestrian, retail, airport apron, parking, church
-    grey2:       [0.5, 0.5, 0.5]          # airport runway
-    grey3:       '#bbbbbb'                # railway
-    grey4:       '#ffc52a'                # airport taxiway
-    grey5:       '#ffc52a'                # airport taxiway
-    grey6:       '#dddddd'                # industrial
-    grey6_b:     [.65, .65, .65]          # industrial buildings
-    grey6_bo:    [.8, .8, .8]             # industrial building outlines
-    grey7:       '#ecebe9'                # pedestrian, match minor road / path color
-    grey7_v:     true                     # pedestrian visibility
-    grey8:       '#ecebe9'                # winter sports
-    grey8_v:     true                     # winter sports visibility
-    grey9:       [.7, .0, .0, 0.5]        #[.7, .7, .7]        # transit platform
-    grey9_o:     [.5, .5, .5]             # transit platform outline
-    grey9_v:     true                     # transit platform visibility
-    grey10:      '#d4cce6'                # generic major landuse (theme park, resort, aquarium, winery)
-    grey10_o:    '#bcb9c5'                # generic major landuse outline
-    grey11:      '#d7d7d7'                # generic minor landuse (attraction, artwork)
-    grey11_o:    '#cccccc'                # generic minor landuse outline
-    grey12:      '#cfcfcf'                # generic minor amusements (roller coasters, rides, slide, carousel)
-    grey12_o:    '#c5c5c5'                # generic minor amusements
-    purple:      '#f0e1e1'                # airport
-    purple_v:    true                     # airport
-    mystry1:     '#aaaaaa'                # recreation ground (type of park, sometimes around reservoirs)
-    building1:   white                    # building
-    building2:   white                    # building stroke
-    building_o:  25                       # building stroke order
-    building_e:  true                     # building stroke order
-
-    #labels:
-    text_fill:          '#000'                  # WHITE
-    text_fill2:         '#000'                  # WHITE
-    text_fill_road_e:   '#555'                  # WHITE
-    text_fill_exits:    [0.40,0.40,0.40]        # motorway junctions, highway_casing1
-    text_fill_building: '#000'                  # tan
-    text_fill_address:  [0.60,0.60,0.60]        # HUH
-    text_fill_water:    [0.354,0.531,0.620]     # blue
-    text_fill_park:     [0.175,0.175,0.175]     # green
-    text_fill_beach:    [0.35,0.35,0.35]        # black
-    text_fill_piste:    [0.350,0.350,0.350]     # dark gray
-    text_fill_piste_e:  [0.350,0.350,0.350]     # dark gray early
-    text_stroke:        [0.913,0.925,0.933]     # land color
-    text_stroke_park:   [0.913,0.925,0.933]     # land color
-    text_stroke_water:  [0.913,0.925,0.933]
-    text_stroke_address:   [0.913,0.925,0.933]  # address stroke color
-    townspot_sprite:    townspot-m-rev          # depends on land color and text settings
-    text_font_family:   'Open Sans'             # branding in asperational Unicode, yo (or Helvetica)
+    # TODO: YAML based globals below will move into this Tangram globals block
+
+labels-global:
+    - &text_visible_continent         true
+    - &text_visible_island            true
+    - &text_visible_admin             true
+    - &text_visible_populated_places  true
+    - &icon_visible_populated_places  true
+    - &text_visible_neighbourhoods    true
+    - &text_visible_neighbourhoods_e  true
+    - &text_visible_building          true
+    - &text_visible_address           true
+    - &text_visible_water_labels      true
+    - &label_visible_landuse_green    true
+    - &icon_visible_landuse_green     true      #this needs work
+    - &text_visible_landuse_green     true
+    - &label_visible_poi_landuse      true
+    - &icon_visible_poi_landuse       true      #false for default
+    - &text_visible_poi_landuse       true      #false for default
+    - &label_visible_poi_landuse_e    true
+    - &icon_visible_poi_landuse_e     true      #false for default
+    - &text_visible_poi_landuse_e     true
+    - &label_visible_station          true      #false for default
+    - &icon_visible_station           true      #false for default
+    - &text_visible_station           true      #false for default
+    - &text_visible_highway           true
+    - &text_visible_highway_e         true      #false for default
+    - &text_visible_trunk_primary     true
+    - &text_visible_trunk_primary_e2  true      #false for default
+    - &text_visible_trunk_primary_e   true      #false for default
+    - &text_visible_secondary         true
+    - &text_visible_secondary_e       true      #false for default
+    - &text_visible_tertiary          true
+    - &text_visible_tertiary_e        true      #false for default
+    - &text_visible_minor_road        true
+    - &text_visible_minor_road_e      true
+    - &text_visible_service_road      true
+    - &text_visible_path              true
+    - &text_visible_piste             true
+    - &text_visible_steps             true
+    - &text_visible_aerialway         true
+    - &text_visible_shields           false
+    - &text_visible_exits             true
+    - &text_visible_exits_e           true      #false for default
+    - &text_visible_airport_gate      true
+
+settings:
+    cameras:
+        - &camera_settings            { type: isometric, axis: [-.2, .2] }
+
+    lights:
+        - &light_settings             { type: directional, direction: [1, 1, -.9], diffuse: 0.5, ambient: 0.85 }
+
+    roads:
+        - &highway1                   [1.00,1.00,1.00]
+        - &highway_link1              [0.00, 0.00, 0.00]
+        - &highway_casing1            [0.894,0.906,0.914]
+        - &highway_tunnel1            [0.930,0.930,0.930]
+        - &highway_tunnel_casing1     [0.894,0.906,0.914]
+        - &highway_link_tunnel_casing1 [0.350,0.350,0.350]
+        - &ferry1                     [0.410,0.750,0.833]
+        - &rail1                      '#999'
+        - &rail1_e                    '#bbb'
+        - &rail2                      '#777'             # less important rail (service, sidings)
+        - &major_road1                [1.0, 1.0, 1.0]
+        - &major_road1b               [0.935, 0.935, 0.935]
+        - &major_road1c               white    #15%
+        - &major_road2                [0.935, 0.935, 0.935]
+        - &major_road2a               [0.935, 0.935, 0.935]
+        - &major_road2b               [0.935, 0.935, 0.935]
+        - &major_road3                [0.935, 0.935, 0.935]
+        - &major_road4                [0.00, 0.00, 0.00]
+        - &major_road5                white
+        - &major_casing1              [0.40, 0.40, 0.40]        # same as highway_casing1
+        - &major_casing2              [0.40, 0.40, 0.40]        # zoomed out
+        - &major_tunnel1              [0.930,0.930,0.930]
+        - &major_tunnel_casing1       [1.00, 1.00, 1.00]
+        - &major_route1               [0.0, 0.0, 0.0]
+        - &major_route2               [0.2, 0.2, 0.2]           # zoomed out
+        - &minor_route                [0.97, 0.97, 0.97]        # same as major_route
+        - &minor_road1                [0.935, 0.935, 0.935]     # natural earth
+        - &minor_road2                [1.00,1.00,1.00]     # natural earth, same as major_road2
+        - &minor_road3                [0.935, 0.935, 0.935]
+        - &minor_road4                [0.935, 0.935, 0.935]     # zoomed out
+        - &minor_road5                [0.935, 0.935, 0.935]     # zoomed out, again
+        - &minor_casing1              white                     # same as highway_casing1
+        - &minor_casing2              white                     # zoomed out
+        - &minor_tunnel1              [0.930,0.930,0.930]
+        - &minor_tunnel_casing1       [1.00, 1.00, 1.00]
+        - &service_road1              [0.935, 0.935, 0.935]
+        - &service_road2              white
+        - &service_road_casing1       [0.40, 0.40, 0.40]
+        - &service_road_casing2       white
+        - &path1                      [0.97, 0.97, 0.97]
+        - &path2                      [0.97, 0.97, 0.97]        # zoomed out
+        - &path_casing1               [0.40, 0.40, 0.40]
+        - &path_bridge_casing1        [0.40, 0.40, 0.40]
+        - &path_bridge_casing2        [0.40, 0.40, 0.40]        # zoomed out
+        - &path_steps1                red
+        - &path_steps1_b              '#ccc'
+        - &piste_easy                 [0.367,0.750,0.622]
+        - &piste_intermediate         [0.420,0.678,0.863]
+        - &piste_advanced             [0.450,0.450,0.450]
+        - &piste_expert               [0.450,0.450,0.450]
+
+    boundaries:
+        - &country_boundary           [1.00,1.00,1.00]
+        - &region_boundary            [1.00,1.00,1.00]
+        - &subregion_boundary         [1.00,1.00,1.00]
+        - &city_wall                  [0.682,0.682,0.682]
+        - &retaining_wall             [0.827,0.808,0.780]
+        - &snow_fence                 [0.827,0.808,0.780]
+        - &fence                      [0.827,0.808,0.780]
+        - &dam                        [0.827,0.808,0.780]
+
+    areas:
+        - &scene1      white                    # map background
+        - &water1      [0.870, 0.870, 0.870]    # water wave
+        - &water2      [0.760, 0.760, 0.760]    # water wave
+        - &water3      [0.5, 0.5, 0.5]          # playa texture
+        - &water1_o    '#fff'                   # water stroke (ocean coastline)
+        - &water2_o    '#d1d1d1'                # water stroke 2 (streams, lake outlines)
+        - &earth1      white                    # land color
+        - &earth2      '#e9e4e0'                # urban
+        - &earth2_v    false                    # urban
+        - &green1      [0.50,0.50,0.50]         # park
+        - &green1_r    '#bbbbbb'                # park roads
+        - &green1_b    [.65, .65, .65]          # park buildings
+        - &green1_bo   [.8, .8, .8]             # park building outlines
+        - &green2      [0.90,0.90,0.90]         # cemetery
+        - &green3      '#9a9a9a'                # golf course
+        - &green4      [0.90,0.90,0.90]         # farm faint
+        - &green4_v    false                    # farm faint
+        - &green5      [0.75,0.75,0.75]         # farm
+        - &green6      [0.40,0.40,0.40]         # nature reserve
+        - &green7      [0.85,0.85,0.85]         # forest
+        - &green8      [0.80,0.80,0.80]         # conservation
+        - &green9      [0.85,0.85,0.85]         # forest (landcover)
+        - &green9_e    [0.90,0.90,0.90]         # forest (landcover) early
+        - &green9_v    true                     # forest (landcover) visibility
+        - &green10     [0.85,0.85,0.85]         # sports_centre
+        - &green11     [0.85,0.85,0.85]         # minor zoo related AOIs
+        - &green11_o   [0.85,0.85,0.85]         # minor zoo related AOIs outline
+        - &orange1     '#aaaaaa'                # stadium
+        - &orange2     [0.40,0.40,0.40]         # pitch (play field)
+        - &brown1      '#7b7b7b'                # university
+        - &brown1_r    '#bbbbbb'                # university roads
+        - &brown1_b    [.65, .65, .65]          # university buildings
+        - &brown1_bo   [.8, .8, .8]             # university building outlines
+        - &brown2      '#aaaaaa'                # school
+        - &brown3      [0.40,0.40,0.40]         # playground
+        - &red1        '#a2a2a2'                # hospital
+        - &red1_r      '#bbbbbb'                # hospital roads
+        - &red1_b      [.65, .65, .65]          # hospital buildings
+        - &red1_bo     [.8, .8, .8]             # hospital building outlines
+        - &gray-all    [0.935,0.960,0.970]      # default gray for landuse outdoor style
+        - &grey1       '#cccccc'                # pedestrian, retail, airport apron, parking, church
+        - &grey1_e     '#dad6d4'                # pedestrian, retail, airport apron, parking, church early zoom 14
+        - &grey1_v     true                     # pedestrian, retail, airport apron, parking, church
+        - &grey2       [0.5, 0.5, 0.5]          # airport runway
+        - &grey3       '#bbbbbb'                # railway
+        - &grey4       '#ffc52a'                # airport taxiway
+        - &grey5       '#ffc52a'                # airport taxiway
+        - &grey6       '#dddddd'                # industrial
+        - &grey6_b     [.65, .65, .65]          # industrial buildings
+        - &grey6_bo    [.8, .8, .8]             # industrial building outlines
+        - &grey7       '#ecebe9'                # pedestrian, match minor road / path color
+        - &grey7_v     true                     # pedestrian visibility
+        - &grey8       '#ecebe9'                # winter sports
+        - &grey8_v     true                     # winter sports visibility
+        - &grey9       [.7, .0, .0, 0.5]        #[.7, .7, .7]        # transit platform
+        - &grey9_o     [.5, .5, .5]             # transit platform outline
+        - &grey9_v     true                     # transit platform visibility
+        - &grey10      '#d4cce6'                # generic major landuse (theme park, resort, aquarium, winery)
+        - &grey10_o    '#bcb9c5'                # generic major landuse outline
+        - &grey11      '#d7d7d7'                # generic minor landuse (attraction, artwork)
+        - &grey11_o    '#cccccc'                # generic minor landuse outline
+        - &grey12      '#cfcfcf'                # generic minor amusements (roller coasters, rides, slide, carousel)
+        - &grey12_o    '#c5c5c5'                # generic minor amusements
+        - &purple      '#f0e1e1'                # airport
+        - &purple_v    true                     # airport
+        - &mystry1     '#aaaaaa'                # recreation ground (type of park, sometimes around reservoirs)
+        - &building1   white                    # building
+        - &building2   white                    # building stroke
+        - &building_o  25                       # building stroke order
+        - &building_e  true                     # building stroke order
+
+    labels:
+        - &text_fill   '#000'                       # WHITE
+        - &text_fill2  '#000'                       # WHITE
+        - &text_fill_road_e   '#555'                # WHITE
+        - &text_fill_exits    [0.40,0.40,0.40]      # motorway junctions, highway_casing1
+        - &text_fill_building '#000'                # tan
+        - &text_fill_address  [0.60,0.60,0.60]      # HUH
+        - &text_fill_water   [0.354,0.531,0.620]    # blue
+        - &text_fill_park    [0.175,0.175,0.175]    # green
+        - &text_fill_beach   [0.35,0.35,0.35]      # black
+        - &text_fill_piste   [0.350,0.350,0.350]    # dark gray
+        - &text_fill_piste_e [0.350,0.350,0.350]    # dark gray early
+        - &text_stroke       [0.913,0.925,0.933]    # land color
+        - &text_stroke_park  [0.913,0.925,0.933]     # land color
+        - &text_stroke_water [0.913,0.925,0.933]
+        - &text_stroke_address   [0.913,0.925,0.933]      # address stroke color
+        - &townspot_sprite   townspot-m-rev         # depends on land color and text settings
+        - &text_font_family  'Open Sans'            # branding in asperational Unicode, yo (or Helvetica)
 
 cameras:
-    camera1: global.camera_settings
+    camera1: *camera_settings
 
 scene:
     background:
@@ -448,7 +444,6 @@ fonts:
 textures:
     pois:
         url: images/walkabout@2x.png
-        #url: https://raw.githubusercontent.com/tangrams/walkabout-style/gh-pages/images/walkabout%402x.png
         filtering: mipmap
         sprites:
             # define sprites: [x origin, y origin, width, height]
@@ -658,6 +653,7 @@ textures:
             outdoor: [736, 252, 38, 38]
             park: [322, 126, 38, 38]
             national_park: [322, 126, 38, 38]
+            battlefield: [322, 126, 38, 38]
             protected_area: [322, 126, 38, 38]
             category-predicate-nature: [322, 126, 38, 38]
             parking: [782, 126, 38, 38]
@@ -776,25 +772,20 @@ textures:
 
     building-grid:
         url: images/building-grid.gif
-        #url: https://raw.githubusercontent.com/tangrams/walkabout-style/gh-pages/images/building-grid.png
         filtering: mipmap
 
 sources:
     mapzen:
         type: TopoJSON
         # prod
-        url:  https://tile.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.topojson
+        url:  https://tile.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.topojson?api_key=vector-tiles-VyYjZGS
         # dev
         #url:  https://tile.dev.mapzen.com/mapzen/vector/v1/all/{z}/{x}/{y}.topojson
-        url_params:
-            api_key: global.sdk_mapzen_api_key
         rasters: [normals]
         max_zoom: 16
     normals: # normals
         type: Raster
         url: https://tile.mapzen.com/mapzen/terrain/v1/normal/{z}/{x}/{y}.png
-        url_params:
-            api_key: global.sdk_mapzen_api_key
         max_zoom: 15
 
 #    # Only enable this for local debug, should not be enabled for prod (app inserts these at runtime)
@@ -876,35 +867,190 @@ styles:
         base: lines
         dash: [1.25, 1.25]
         dash_background_color: [0.808,0.860,0.851]
-    dashed_small:
-        base: lines
-        dash: [0.5, 0.5]
-        dash_background_color: [0.867, 0.867, 0.867]
     dashed_big:
         base: lines
         dash: [2.0, 1.0]
         dash_background_color: [0.808,0.860,0.851]
-    dashed_tunnel:
+    dashedTunnel:
         base: lines
         dash: [5, 3]
         #dash_background_color: red
+    dashedline:
+        base: lines
+        texcoords: true
+        shaders:
+            defines:
+                background: vec3(0.867, 0.867, 0.867)
+            blocks:
+                color: |
+                    // blend line 50/50 between two colors
+                    float t = fract(v_texcoord.y*.5);
+                    float e = 0.1; // edge feather
+                    vec3 v = vec3(
+                        smoothstep(.0, e, t) *
+                        (1. - smoothstep(.5, .5 + e, t))
+                    );
+                    color.rgb = mix(color.rgb, background, v);
+
+    functions-map:
+        shaders:
+            defines:
+                EPSILON: 0.0000001
+            blocks:
+                global: |
+                    float map (in float value, in float inputMin, in float inputMax, in float outputMin, in float outputMax, bool clamp) {
+                        if (abs(inputMin - inputMax) < EPSILON){
+                            return outputMin;
+                        } else {
+                            float outVal = ((value - inputMin) / (inputMax - inputMin) * (outputMax - outputMin) + outputMin);
+
+                            if( clamp ){
+                                if(outputMax < outputMin){
+                                    if( outVal < outputMax ) outVal = outputMax;
+                                    else if( outVal > outputMin ) outVal = outputMin;
+                                } else {
+                                    if( outVal > outputMax ) outVal = outputMax;
+                                    else if( outVal < outputMin ) outVal = outputMin;
+                                }
+                            }
+                            return outVal;
+                        }
+                    }
+
+                    float map (in float value, in float inputMin, in float inputMax, in float outputMin, in float outputMax) {
+                        return map(value, inputMin, inputMax, outputMin, outputMax, true);
+                    }
+    space-tile:
+        shaders:
+            blocks:
+                global: |
+                    // Variant to be add to both vertex and fragments shaders
+                    varying vec3 v_pos;
+                    //
+                    // Get the coordinates in tile space
+                    // ================================
+                    vec2 getTileCoords () {
+                        return fract(v_pos.xy);
+                    }
+                position: |
+                    // Normalize the attribute position of a vertex
+                    v_pos = modelPosition().xyz;
+
+    grids-grid:
+        shaders:
+            blocks:
+                global: |
+                    // Draw a grid in the space a specific resolution and pressition
+                    bool grid(vec2 st, float res, float press){
+                        vec2 grid = fract(st*res);
+                        return grid.x < res*press || grid.y < res*press;
+                    }
+                    //
+                    // Draw a grid in the space a specific resolution
+                    bool grid(vec2 st, float res){
+                        return grid(st, res, 1.0);
+                    }
+
+    grids-tile:
+        mix: [space-tile,grids-grid]
+        shaders:
+            blocks:
+                global: |
+                    // Draw a grid using tile coordenates in a specific resolution
+                    float tileGrid(float res){
+                        vec2 st = getTileCoords()*100.*res;
+                        float pct = 0.0;
+                        float press = .4+(1.0-fract(u_map_position.z))*0.1; //0.4
+                        if (grid(st,0.01,press)) pct += .5; //.5
+                        return pct;
+                    }
+                    // Draw two grid that smoothly interpolates acording to zooms
+                    float tileGrid(){
+                        return mix(tileGrid(1.),tileGrid(2.),fract(u_map_position.z));
+                    }
+
+    grid:
+        base: polygons
+        mix: [grids-tile]
+        shaders:
+            blocks:
+                color: |
+                    color = v_color*tileGrid();
+                    // color = vec4(v_color.r, v_color.g, v_color.b, 1.0);
+                    // color.rgba
+
+    shapes-rect:
+        shaders:
+            blocks:
+                global: |
+                    // get distance field of a rectangle in the center
+                    // ================================
+                    float rectDF(vec2 st, vec2 size) {
+                        //float aspect = u_resolution.x/u_resolution.y;
+                        st = st*2.-1.;
+                        //st.x *= aspect;
+                        return length(max(abs(st)-size,.0));
+                    }
+                    float rectDF(vec2 st, float size) {
+                        //float aspect = u_resolution.x/u_resolution.y;
+                        st = st*2.-1.;
+                        //st.x *= aspect;
+                        return length(max(abs(st)-size,.0));
+                    }
+
+                    // Draw a round corners rectangle in the center
+                    // ================================
+                    float rect(vec2 st, vec2 size, float radio) {
+                        radio = max(.000001, radio);
+                        return 1.0-step(radio, rectDF(st, size-radio));
+                    }
+
+                    float rect(vec2 st, float size, float radio) {
+                        return rect(st,vec2(size),radio);
+                    }
+
+                    // Draw a rectangle in the center
+                    // ================================
+                    float rect(vec2 st, vec2 size){
+                        size = .25-size*.125;
+                        vec2 uv = step(size,st*(1.0-st));
+                        return (uv.x*uv.y);
+                    }
+
+                    float rect(vec2 st, float size){
+                        return rect(st,vec2(size));
+                    }
+    shapes-cross:
+        mix: shapes-rect
+        shaders:
+            blocks:
+                global: |
+                    // Draw a Cross in the middle of the ST space
+                    float cross (vec2 st, float size, float width) {
+                        return  clamp(  rect(st, vec2(size*0.5,width*0.125)) +
+                                        rect(st, vec2(width*0.125,size*0.5)),0.,1.);
+                    }
+                    float cross(in vec2 st, float _size){
+                        return  rect(st, vec2(_size*0.5,_size*0.125)) +
+                                rect(st, vec2(_size*0.125,_size*0.5));
+                    }
+                    float cross(in vec2 st, vec2 _size){
+                        return  rect(st, vec2(_size.x*0.5,_size.y*0.125)) +
+                                rect(st, vec2(_size.y*0.125,_size.x*0.5));
+                    }
+
     terrain:
         base: polygons
         lighting: false
-        raster: custom
+        raster: normal
         shaders:
             uniforms:
                 # u_envmap: images/relief-shading-environment-map.jpg
-                u_envmap: images/draw-test10.jpg
-                # u_envmap: https://raw.githubusercontent.com/tangrams/walkabout-style/gh-pages/images/draw-test10.jpg
+                u_envmap: images/draw-test9.jpg
                 u_contrast: 1.
                 u_brightness: 1.
             blocks:
                 global: |
-                    varying vec2 v_tex_coord;
-                    #ifdef TANGRAM_VERTEX_SHADER
-                    uniform vec3 u_raster_offsets[TANGRAM_NUM_RASTER_SOURCES];
-                    #endif
                     // Simplified view-independent environment map
                     vec4 terrainEnvmap (in sampler2D _tex, in vec3 _normal) {
                         const vec3 eye = vec3(0.,0.,-1.);
@@ -915,24 +1061,17 @@ styles:
                         return texture2D(_tex, uv);
                     }
                     const float e = 2.71828;
-                setup: |
-                    #ifdef TANGRAM_VERTEX_SHADER
-                    v_tex_coord = modelPositionBaseZoom().xy * u_raster_offsets[0].z + u_raster_offsets[0].xy;
-                    #endif
                 color: |
                     // scale up normals with a function
                     // https://www.desmos.com/calculator/bv4mzh8erz
                     //float scale = 10./(u_map_position.z-.7) + 1.8;
                     float scale1 = 20./(u_map_position.z) + 1.5;
-
-                    vec3 tex_normal = normalize(texture2D(u_rasters[0], v_tex_coord).xyz * 2.0 - 1.0);
-                    tex_normal.z /= scale1; // turn terrain exaggeration up/down
-
+                    normal.z /= scale1; // turn terrain exaggeration up/down
                     // fade out spheremap normals with a function
                     // https://www.desmos.com/calculator/ptgkzcnfyc
                     float m = 3.5 * (u_map_position.z - 0.8) * pow(e, u_map_position.z * -.29);
                     m = clamp(m, 0., 1.5);
-                    color = terrainEnvmap(u_envmap, tex_normal);
+                    color = terrainEnvmap(u_envmap, normal);
 
                     // Apply contrast
                     float contrast = m;
@@ -943,6 +1082,17 @@ styles:
 
                     color *= v_color; // apply layer color
 
+    water-grid:
+        mix: grid
+        shaders:
+            blocks:
+                color: |
+                    color = v_color;
+                    color.rgb -= vec3(tileGrid());
+                    vec4 linecolor = vec4(0.489,0.776,0.820,1.0);
+                    vec4 colorlines = linecolor * tileGrid();
+                    color += colorlines;
+
     # HSV/RGB functions
     hsv:
         shaders:
@@ -1006,6 +1156,71 @@ styles:
         base: lines
         mix: scale-buildings
         texcoords: true
+
+
+    terrain-muted:
+        mix: grid-on-terrain
+        shaders:
+            uniforms:
+                u_scale: 1 # turn down the terrain
+
+    terrain-grid:
+        mix: grid-on-terrain
+        shaders:
+            uniforms:
+                u_scale: 2
+
+    grid-on-terrain:
+        mix: [grids-tile, terrain]
+        shaders:
+            blocks:
+                color: |
+                    color -= v_color*tileGrid();
+                    vec4 linecolor = vec4(0.489,0.776,0.820,1.0);
+                    color += linecolor * tileGrid();
+    dots-terrain:
+        mix: [space-tile, functions-map, terrain, shapes-cross]
+        shaders:
+            blocks:
+                color: |
+                    // Brightness
+                    float brightness2 = dot(normal, vec3(-0.838,-1.010,0.805));
+
+                    brightness2 = 1.-brightness2;
+
+                    // Scale
+                    float scale2 = map(floor(u_map_position.z), 8., 22., 0.0000001, .1, true);
+                    vec2 st = worldPosition().xy*scale2;
+
+
+                    // PATERNS
+                    float pct = 0.0;
+
+                    // Stripes
+                    // pct = step(brightness2*4.556,cos((st.x+st.y)));
+
+
+                    // Cell patterns
+                    st.x += step(1., mod(st.y,2.0)) *.5;
+                    vec2 f_st = fract(st);
+                    f_st -= .5;
+
+                    // Dots
+                     pct = step(brightness2*2.056,1.-dot(f_st,f_st)*10.400);
+
+                    // Lines
+                    // pct = rect(f_st+0.5,vec2(0.704,brightness2*0.472));
+
+                    // Cross
+                    //pct = cross(f_st+0.5,brightness2*6.128,brightness2*2.604);
+
+                    // Use this if you tint
+                    // if (pct < .5) {
+                        // discard;
+                    // }
+
+                    color.rgb = mix(color.rgb, v_color.rgb ,pct);
+
     icons:
         base: points
         texture: pois
@@ -1100,7 +1315,9 @@ layers:
                 sprite: ux-current-location
                 size: 36px
                 collide: false
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_route_location:
         data: { source: mz_route_location }
         draw:
@@ -1108,7 +1325,9 @@ layers:
                 sprite: ux-route-arrow
                 size: [60px,60px]
                 collide: false
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_route_start:
         data: { source: mz_route_start }
         draw:
@@ -1119,7 +1338,9 @@ layers:
                 size: [36px,46px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_route_destination:
         data: { source: mz_route_destination }
         draw:
@@ -1130,7 +1351,9 @@ layers:
                 size: [36px,46px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_route_transit_stop:
         data: { source: mz_route_transit_stop }
         draw:
@@ -1139,7 +1362,9 @@ layers:
                 sprite: ux-transit-stop
                 size: [15px,15px]
                 collide: false
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                         time: 0s
     mz_search_result:
         data: { source: mz_search_result }
         draw:
@@ -1149,7 +1374,9 @@ layers:
                 size: [36px,54px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
         inactive:
             filter: { state: inactive }
             draw:
@@ -1164,7 +1391,9 @@ layers:
                 size: [36px,54px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
 
     # Used by the SDK to place point, line, and polygon overlays on the map
     mz_default_point:
@@ -1176,7 +1405,9 @@ layers:
                 size: [36px,54px]
                 collide: false
                 anchor: top
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
     mz_default_shield:
         data: { source: mz_default_shield }
         draw:
@@ -1193,7 +1424,9 @@ layers:
                 sprite_default: sdk_shield-1char
                 color: global.sdk_shield_color
                 collide: false
-                transition: { show: { time: 0s }, hide: { time: 0s } }
+                transition:
+                    [show, hide]:
+                        time: 0s
                 text:
                     # offset: [0px, -1px]
                     text_source: |
@@ -1354,7 +1587,7 @@ layers:
         playas:
             filter: { kind: playa, $zoom: {min: 6} }
             draw:
-                dashed_small:
+                dashedline:
                     order: function() { return feature.sort_rank; }
                     color: grey
                     width: 1px
@@ -1471,7 +1704,7 @@ layers:
 
     water-line-labels:
         data: { source: mapzen, layer: water }
-        visible: global.text_visible_water_labels
+        visible: *text_visible_water_labels
         filter:
             all:
                 - name: true
@@ -1482,8 +1715,8 @@ layers:
             text-blend-order:
                 text_source: global.ux_language_text_source
                 font:
-                    fill: global.text_fill_water
-                    family: global.text_font_family
+                    fill: *text_fill_water
+                    family: *text_font_family
                     style: italic
                     weight: normal
                     size: [[12,10px],[17,14px]]
@@ -1571,12 +1804,12 @@ layers:
                 visible: false    # labels are enabled by each layer below
                 text_source: global.ux_language_text_source
                 font:
-                    family: global.text_font_family
+                    family: *text_font_family
                     weight: 500
-                    fill: global.text_fill
+                    fill: *text_fill
 
         early:
-            filter: { $zoom: { max: 14 } }
+            filter: { $zoom: { max: 15 } }
             draw:
                 lines:
                     outline:
@@ -1602,119 +1835,187 @@ layers:
             filter: { source: 'naturalearthdata.com', $zoom: { max: 8 } }
             draw:
                 lines:
-                    color: [[5, [0.50,0.50,0.50]], [6, [0.350,0.350,0.350]]]
-                    width: [[5, 0.5px], [8, 1.25px]]
+                    color: [[5, [0.5,0.5,0.5]],[6, [0.350,0.350,0.350]]]
+                    width: [[5, 0.5px], [6, 0.5px], [7, 0.75px], [9, 1.5px], [14, 1.5px], [16, 4px], [17, 10m]]
                     outline:
-                        color: global.highway_casing1
-                        width: 0px
+                        color: *highway_casing1
+                        width: [[9, 0px], [10, 0px], [12, 1px], [16, 2px]]
             major_road:
                 filter: { kind: major_road }
                 draw:
                     lines:
-                        color: [[5, [0.75,0.75,0.75]], [8, [0.40,0.40,0.40]]]
-                        width: [[5, 0.25px], [9, 0.75px]]
+                        color: [[5, [0.75,0.75,0.75]], [8, [0.4,0.4,0.4]], [13, [0.4,0.4,0.4]], [17, *major_road1]]
+                        #color: red
+                        width: [[5, 0.25px], [7, 0.5px], [7, 0.75px], [9, 1px], [10, 9px], [11, 9px], [13, 1px], [16, 2.5px], [19, 6m]]
                         outline:
                             width: [[8, 0.0px], [9, 0.0px], [11, .5px], [16, .75px]]
             minor_road:
                 filter: { kind: minor_road }
                 draw:
                     lines:
-                        color: global.minor_road1
-                        width: 0.5px
+                        color: [[12, *minor_road1], [17, *minor_road2]]
+                        width: [[12, 1.0px], [14, 1.5px], [15, 3px], [16, 5m]]
+                        # outline:
+                        #     width: [[12, 0px], [14, .5px], [17, 1px]]
             ferry:
                 filter: { kind: ferry }
                 draw:
                     lines:
-                        color: global.ferry1
-                        width: 0.5px
+                        color: *ferry1
+                        width: [[12, 0.5px], [13, 0.75px], [15, 1.0px]]
                         outline:
                             width: 0px
         highway:
             filter: { kind: highway, $zoom: { min: 8 } }
             draw:
                 lines:
-                    color: [[8, [0.457,0.438,0.457]], [10, [0.548,0.483,0.491]], [11, [1.00,1.00,1.00]]]
-                    width: [[8, 1.25px], [12, 1.5px], [14, 2.5px], [16, 5.5px], [17, 10px], [18, 10m]]
+                    color: [[8, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                    width: [[8, 1px], [12, 1.25px], [13, 1.5px], [14, 0px], [15, 1px], [16, 5px], [17, 10px], [18, 10m]]
                     outline:
-                        color: [[8, [0.969,0.969,0.969]], [10, [0.969,0.969,0.969]], [11, [0.548,0.483,0.491]]]
-                        width: [[8, 1px], [10, 1px], [12, 1.5px], [14, 1.75px], [16, 2.5px], [18, 4px]]
-            early:
-                filter: { $zoom: { max: 15 } }          # was max: 15 (11)
-                draw:
-                    lines:
-                        outline:
-                            order: function() { return feature.sort_rank; }
+                        color: [[8, [0.894,0.906,0.914]], [13, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [16, [0.408,0.430,0.461]]]
+                        width: [[8,0px], [13,0px], [14,1px], [15,2px], [16, 3px], [17, 4px], [18, 5px]]
+                #dashedTunnel:
+                #    width: [[8, 1px], [12, 1.25px], [13, 1.5px], [14, 0px], [15, 1px], [16, 5px], [17, 10px], [18, 10m]]
             link:
                 filter: { is_link: true } # on- and off-ramps, etc
                 draw:
                     lines:
-                        color: [[11, [0.627,0.612,0.616]], [13, [0.627,0.612,0.616]], [14, [1.00,1.00,1.00]]]
-                        width: [[8, 0px], [11, 0.4px], [12, 0.6px], [14, 1.25px], [16, 3px], [18, 5m]]
+                        #color: *highway_link1
+                        color: [[9, [0.50,0.50,0.50]], [13, [0.408,0.430,0.461]], [14, [1.0,1.0,1.0]], [15, [1.0,1.0,1.0]]]
+                        width: [[9, 0px], [11, 0.15px], [12, 0.5px], [13, 0.75px], [14, 0px], [15, 1px], [16, 2.5px], [17, 4px], [18, 8px], [19, 8px]]
                         outline:
-                            color: [[11, [0.969,0.969,0.969]], [13, [0.969,0.969,0.969]], [14, [0.548,0.483,0.491]]]
-                            width: [[8, 0px], [9, 0px], [13, 0px], [14, 0.6px], [16, 1.25px], [18, 2px]]
+                            color: [[9,[0.894,0.906,0.914]], [13, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [15, [0.408,0.430,0.461]]]
+                            width: [[9, 0px], [13, 0px], [14, 0.5px], [15, 1px], [16, 2px], [17, 2px], [18, 2px]]
                 early_link:
-                    filter: { $zoom: { max: 15 } }
+                    filter: { $zoom: {min: 13, max: 15} }
                     draw:
                         lines:
                             order: 352
-                    z12-13:
-                        filter: { $zoom: { max: 14 } }
-                        draw:
-                            lines:
-                                order: 351
                 tunnel-link:
-                    filter: { is_tunnel: true, $zoom: { min: 13 } }
+                    filter: {is_tunnel: true, $zoom: {min: 13} }
                     draw:
                         lines:
-                            color: [0.929,0.929,0.929]
+                            color: [[13,[0.790,0.790,0.790]], [14,[0.820,0.820,0.820]], [15,[0.950,0.950,0.950]], [16,[0.950,0.950,0.950]]]
                             outline:
-                                color: [0.695,0.739,0.790]
+                                color: [0.900,0.900,0.900]
             tunnel:
-                filter: { is_tunnel: true, $zoom: { min: 13 } }
+                filter: {is_tunnel: true, $zoom: {min: 13} }
                 draw:
+                    #dashedTunnel:
+                    #    color: blue
+                    #    order: function() { return (feature.sort_rank - 1); }
                     lines:
-                        color: [0.929,0.929,0.929]
+                        #visible: false
+                        color: [[13,[0.710,0.710,0.710]], [14,[0.779,0.802,0.828]], [15,[0.950,0.950,0.950]], [16,[0.950,0.950,0.950]]]
                         outline:
-                            color: [0.695,0.739,0.790]
+                            color: [[13, [0.720,0.720,0.720]], [14, [0.770,0.770,0.770]], [15, [0.80,0.80,0.80]], [16, [0.825,0.825,0.825]]]
             highway_bridge:
-                filter: { is_bridge: true }
+                filter: {is_bridge: true}
                 draw:
                     lines:
                         cap: round
                         outline:
                             cap: butt
-            labels-highway:
+            labels-highway-z13:
+                filter:
+                    $zoom: 13
+                draw:
+                    text-blend-order:
+                        priority: 50
+                        visible: *text_visible_highway
+                        font:
+                            fill: [0.408,0.427,0.459]
+                            weight: 600
+                            size: 11px
+                            stroke: { color: [0.898,0.906,0.910], width: 4 }
+            labels-highway-z14:
+                filter:
+                    $zoom: 14
+                draw:
+                    text-blend-order:
+                        priority: 50
+                        visible: *text_visible_highway
+                        font:
+                            fill: [0.408,0.427,0.459]
+                            weight: 600
+                            size: 11px
+                            stroke: { color: [0.898,0.906,0.910], width: 4 }
+            labels-highway-z15:
                 filter:
-                    $zoom: { min: 13 }
+                    $zoom: 15
+                draw:
+                    text-blend-order:
+                        visible: *text_visible_highway
+                        font:
+                            fill: [1.0,1.0,1.0]
+                            weight: 600
+                            size: 12px
+                            stroke: { color: [0.408,0.427,0.459], width: 4 }
+            labels-highway-z16:
+                filter: { $zoom: { min: 16, max: 18 } }
+                draw:
+                    text-blend-order:
+                        priority: 50
+                        visible: *text_visible_highway
+                        font:
+                            fill: [1.0,1.0,1.0]
+                            weight: 600
+                            size: 13px
+                            stroke: { color: [0.408,0.427,0.459], width: 4 }
+            labels-highway-z17:
+                filter: { $zoom: { min: 17 } }
+                draw:
+                    text-blend-order:
+                        priority: 50
+                        visible: *text_visible_highway
+                        font:
+                            fill: [0.408,0.427,0.459]
+                            weight: 600
+                            size: 15px
+                            stroke: { color: [1.000,1.000,1.000], width: 4 }
+            labels-highway-z18:
+                filter: { $zoom: { min: 18 } }
+                draw:
+                    text-blend-order:
+                        priority: 50
+                        visible: *text_visible_highway
+                        font:
+                            fill: [0.408,0.427,0.459]
+                            weight: 600
+                            size: 16px
+                            stroke: { color: [1.000,1.000,1.000], width: 4 }
+            labels-highway-z19:
+                filter: { $zoom: { min: 19 } }
                 draw:
                     text-blend-order:
                         priority: 50
-                        visible: global.text_visible_highway
+                        visible: *text_visible_highway
                         font:
                             fill: [0.408,0.427,0.459]
                             weight: 600
-                            size: [[13, 11px], [15, 12px], [17, 15px], [19, 16px]]
-                            stroke: { color: [[13, [0.898,0.906,0.910]], [16,[1.000,1.000,1.000]]], width: 4px }
+                            size: 16px
+                            stroke: { color: [1.000,1.000,1.000], width: 4 }
 
         major_road:
             filter: { kind: major_road }
             # default style
             draw:
                 lines:
-                    color: [[8, [0.529,0.556,0.592]], [13, [0.529,0.556,0.592]], [15, [1.00,1.00,1.00]]]
-                    width: [[10, 0px], [13, 0.5px], [16, 2.5px], [18,3px]]
+                    color: [[8, *major_road4], [13, major_road2], [17, [1.0,1.0,1.0]]]
+                    width: [[13, 1px], [14, 1px], [16, 2.5px], [17,3px]]
+                    outline:
+                        width: [[12, 0px], [13, .5px], [15, 1px], [17, 2px]]
             trunk_primary:
                 filter: { kind_detail: [trunk, primary] }
                 draw:
                     lines:
-                        color: [[10, [0.603,0.620,0.642]], [11, [1.00,1.00,1.00]]]
-                        width: [[8, 0.5px], [10, 1px], [12, 1px], [14, 2.5px], [16, 4px], [17, 6px], [18, 9m]]
+                        color: [[8, [0.529,0.556,0.592]], [11, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                        width: [[8, 0px], [11, 0.65px], [12, 0.75px], [13, 1px], [14, 1.5px], [15, 0px], [16, 3px], [17, 6px], [18, 9m]]
                         outline:
-                            color: [[8, [0.969,0.969,0.969]], [10, [0.969,0.969,0.969]], [11, [0.629,0.612,0.615]], [14, [0.714,0.694,0.706]]]
-                            width: [[8, 0.5px], [10, 1px], [14, 1px], [16, 2.25px], [17, 2px], [18, 4px]]
+                            color: [[8,[0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                            width: [[8,0px], [11,0px], [14,0px], [15, 1px], [16, 1.5px], [17, 2px], [18, 4px]]
                 early:
-                    filter: { $zoom: { max: 14 } }
+                    filter: { $zoom: { max: 16 } }
                     draw:
                         lines:
                             order: 352
@@ -1729,241 +2030,583 @@ layers:
                 routes:
                     filter: { ref: true }
                     draw:
+                        #dashedTunnel:
+                        #    width: [[9, 0.5px], [10, 0.5px], [11, 0.75px], [12, 1.25px], [13, 1.25px], [14, 0px], [15, 1px], [16, 4px], [17, 8px], [18, 9m]]
+                        #    outline:
+                        #        color: green
+                        #        width: [[8,0px], [13,0px], [14,0.75px], [15,2px], [16, 3px], [17, 4px], [18, 4px]]
                         lines:
-                            color: [[8, [0.603,0.620,0.642]], [10, [0.603,0.620,0.642]], [11, [1.00,1.00,1.00]]]
-                            width: [[8, 1px], [12, 1px], [14, 2.5px], [16, 5px], [17, 8px], [18, 9m]]
+                            color: [[10, [0.508,0.530,0.561]], [11, [0.408,0.430,0.461]], [13, [0.408,0.430,0.461]], [14,[1.0,1.0,1.0]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                            width: [[9, 0.6px], [10, 0.75px], [11, 1.0px], [12, 1.1px], [13, 0.8px], [14, 0.5px], [15, 1px], [16, 4px], [17, 8px], [18, 9m]]
                             outline:
-                                color: [[8, [0.969,0.969,0.969]], [10, [0.969,0.969,0.969]], [11, [0.629,0.612,0.615]], [14, [0.670,0.623,0.654]]]
-                                width: [[9, 1px], [10, 1px], [12, 1.25px], [16, 2.25px], [17, 4px]]
+                                color: [[8,[0.894,0.906,0.914]], [13, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                                width: [[8,0px], [13,0px], [14,0.75px], [15,2px], [16, 3px], [17, 4px], [18, 4px]]
                     early:
-                        filter: { $zoom: { max: 13 } }
+                        filter: { $zoom: { max: 16 } }
                         draw:
                             lines:
                                 order: function() { return feature.sort_rank + 2; }
                                 outline:
                                     order: 353
-                    earlyz-13:
-                        filter: { $zoom: [13] }
+                    primary-route-in-green:
+                        filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield] }
                         draw:
                             lines:
-                                order: 352
+                                color: [[8, [0.408,0.430,0.461]], [11, [0.408,0.430,0.461]], [14,[0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                                width: [[9, 0.6px], [10, 0.75px], [11, 1.0px], [12, 1.1px], [13, 1.2px], [14, 0.5px], [15, 1px], [16, 4px], [17, 8px], [18, 9m]]
                                 outline:
-                                    order: function() { return feature.sort_rank + 1; }
+                                    color: [[8,[0.894,0.906,0.914]], [13, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                    # national-routes:
+                    #     filter: { network: [US:US, US:I] }
+                    #     draw:
+                    #         lines:
+                    #             color: *major_route1
+                    #             #color: [[8,*major_route2],[9,major_route2],[10,*major_route1]]
+                    #             width: [[8, 1px], [10, 1.15px], [11, 1px], [12, 1px], [14, 1.75px], [15, 3px], [16, 4px], [17, 4px]]
+                    #             outline:
+                    #                 color: [1.0,1.0,1.0]
+                    #                 width: 2px
                     tunnel:
-                        filter: { is_tunnel: true, $zoom: { min: 13 } }
+                        filter: {is_tunnel: true, $zoom: {min: 13} }
                         draw:
+                            #dashedTunnel:
+                            #    color: blue
+                            #    order: function() { return (feature.sort_rank - 1); }
                             lines:
-                                color: [0.883,0.904,0.930]
+                                #visible: false
+                                color: [[13,[0.710,0.710,0.710]], [14,[0.779,0.802,0.828]], [15,[0.950,0.950,0.950]]] #[15,[0.744,0.764,0.792]]
                                 outline:
-                                    color: [0.640,0.703,0.780]
-                    labels-trunk_primary-route:
-                        filter: { $zoom: { min: 14 } }
+                                    color: [[13, [0.720,0.720,0.720]], [14, [0.770,0.770,0.770]], [15, [0.80,0.80,0.80]], [16, [0.825,0.825,0.825]]] #[15, [0.894,0.906,0.914]]
+                    labels-trunk_primary-route-z14:
+                        filter: { $zoom: [14] }
+                        draw:
+                            text-blend-order:
+                                priority: 51
+                                visible: *text_visible_trunk_primary_e2
+                                font:
+                                    fill: [0.495,0.511,0.532]
+                                    size: 11px
+                                    stroke: { color: *text_stroke, width: 3 }
+                    labels-trunk_primary-route-z15:
+                        filter: { $zoom: [15] }
                         draw:
                             text-blend-order:
                                 priority: 51
-                                visible: global.text_visible_trunk_primary
+                                visible: *text_visible_trunk_primary
                                 font:
                                     fill: [0.495,0.511,0.532]
                                     weight: 600
-                                    size: [[14, 11px],[15, 12px], [18, 16px]]
-                                    stroke: { color: [[14, global.text_stroke], [15,[0.969,0.973,0.973]]], width: [[15, 3px], [16, 4px]] }
-                        z14:
-                            filter: { $zoom: [14] }
-                            draw:
-                                text-blend-order:
-                                    visible: global.text_visible_trunk_primary_e2
-                                    font:
-                                        weight: normal  # or 500 or 400?
-                labels-trunk_primary-z11-up:
+                                    size: 12px
+                                    stroke: { color: [0.969,0.973,0.973], width: 3 }
+                    labels-trunk_primary-route-z16:
+                        filter: { $zoom: { min: 16 } }
+                        draw:
+                            text-blend-order:
+                                priority: 51
+                                visible: *text_visible_trunk_primary
+                                font:
+                                    fill: [0.495,0.511,0.532]
+                                    weight: 600
+                                    size: 13px
+                                    stroke: { color: [0.969,0.973,0.973], width: 4 }
+                    labels-trunk_primary-route-z17-z18:
+                        filter: { $zoom: [17,18] }
+                        draw:
+                            text-blend-order:
+                                priority: 51
+                                visible: *text_visible_trunk_primary
+                                font:
+                                    fill: [0.495,0.511,0.532]
+                                    weight: 600
+                                    size: 13px
+                                    stroke: { color: [0.969,0.973,0.973], width: 6 }
+                    labels-trunk_primary-route-z19:
+                        filter: { $zoom: { min: 19 } }
+                        draw:
+                            text-blend-order:
+                                priority: 51
+                                visible: *text_visible_trunk_primary
+                                font:
+                                    fill: [0.495,0.511,0.532]
+                                    weight: 600
+                                    size: 16px
+                                    stroke: { color: [0.969,0.973,0.973], width: 6 }
+                primary-in-green:
+                    filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield] }
+                    draw:
+                        lines:
+                            color: [[8, [0.408,0.430,0.461]], [11, [0.408,0.430,0.461]], [14,[0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                            width: [[9, 0.6px], [10, 0.75px], [11, 1.0px], [12, 1.1px], [13, 1.0px], [14, 0.5px], [15, 1.2px], [16, 4px], [17, 8px], [18, 9m]]
+                            outline:
+                                color: [[8,[0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                                width: [[8,0px], [13,0px], [14,0.75px], [15,1.5px], [16, 3px], [17, 4px], [18, 4px]]
+                    tunnel:
+                        filter: {is_tunnel: true, $zoom: {min: 13} }
+                        draw:
+                            lines:
+                                color: [[13,[0.670,0.670,0.670]], [14,[0.720,0.720,0.720]], [15,[0.920,0.920,0.920]], [16,[0.920,0.920,0.920]]]
+                                outline:
+                                    color: [[13,[0.894,0.906,0.914]],[14,[0.894,0.906,0.914]],[15,[0.744,0.764,0.792]]]
+                                    width: [[13, 0px], [14, 0px], [15, 1px], [16, 1.5px], [17, 2px], [18, 4px]]
+                    # golf_course:
+                    #     filter: { landuse_kind: golf_course }
+                    #     draw:
+                    #         lines:
+                    #             outline:
+                    #                 color: [[10, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
+                    # zoo:
+                    #     filter: { landuse_kind: zoo }
+                    #     draw:
+                    #         lines:
+                    #             outline:
+                    #                 color: [[10, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
+                labels-trunk_primary-z11:
                     filter:
-                        $zoom: { min: 11 }
+                        $zoom: [11]
                     draw:
                         text-blend-order:
                             priority: 51
-                            visible: global.text_visible_trunk_primary_e
+                            visible: *text_visible_trunk_primary_e
                             font:
                                 fill: [0.495,0.511,0.532]
-                                size: [[11, 9px], [12, 10px], [13, 11px], [14, 11px], [15, 12px], [16, 13px],[ 18, 13px],[19, 16px]]
-                                stroke: { color: [[11, global.text_stroke], [15, [0.969,0.973,0.973]]], width: [[11, 2px], [15, 4px], [16, 4px], [17, 6px]] }
-                    z16:
-                        filter: { $zoom: [16] }
-                        draw:
-                            text-blend-order:
-                                visible: global.text_visible_trunk_primary
-                                font:
-                                    weight: 600
+                                size: 9px
+                                stroke: { color: *text_stroke, width: 2 }
+                labels-trunk_primary-z12:
+                    filter:
+                        $zoom: [12]
+                    draw:
+                        text-blend-order:
+                            priority: 51
+                            visible: *text_visible_trunk_primary_e
+                            font:
+                                fill: [0.495,0.511,0.532]
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 3 }
+                labels-trunk_primary-z13:
+                    filter:
+                        $zoom: [13]
+                    draw:
+                        text-blend-order:
+                            priority: 51
+                            visible: *text_visible_trunk_primary
+                            font:
+                                fill: [0.495,0.511,0.532]
+                                size: 11px
+                                stroke: { color: *text_stroke, width: 3 }
+                labels-trunk_primary-z14:
+                    filter:
+                        $zoom: [14]
+                    draw:
+                        text-blend-order:
+                            priority: 51
+                            visible: *text_visible_trunk_primary
+                            font:
+                                fill: [0.495,0.511,0.532]
+                                size: 11px
+                                stroke: { color: *text_stroke, width: 4 }
+                labels-trunk_primary-z15:
+                    filter: { $zoom: [15] }
+                    draw:
+                        text-blend-order:
+                            priority: 51
+                            visible: *text_visible_trunk_primary
+                            font:
+                                fill: [0.495,0.511,0.532]
+                                size: 12px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
+                labels-trunk_primary-z16:
+                    filter: { $zoom: [16] }
+                    draw:
+                        text-blend-order:
+                            priority: 51
+                            visible: *text_visible_trunk_primary
+                            font:
+                                fill: [0.495,0.511,0.532]
+                                weight: 600
+                                size: 13px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
+                labels-trunk_primary-z17:
+                    filter: { $zoom: [17] }
+                    draw:
+                        text-blend-order:
+                            priority: 51
+                            visible: *text_visible_trunk_primary
+                            font:
+                                fill: [0.495,0.511,0.532]
+                                weight: 600
+                                size: 13px
+                                stroke: { color: [0.969,0.973,0.973], width: 6 }
+                labels-trunk_primary-z18:
+                    filter: { $zoom: { min: 18 } }
+                    draw:
+                        text-blend-order:
+                            priority: 51
+                            visible: *text_visible_trunk_primary
+                            font:
+                                fill: [0.495,0.511,0.532]
+                                weight: 600
+                                size: [[18,13px],[19,16px]]
+                                stroke: { color: [0.969,0.973,0.973], width: 6 }
             link:
                 filter: { is_link: true } # on- and off-ramps, etc
                 draw:
                     lines:
-                        color: [[11, [0.627,0.612,0.616]], [13, [0.627,0.612,0.616]], [14, [1.00,1.00,1.00]]]
-                        width: [[8, 0px], [11, 0.4px], [12, 0.6px], [14, 1.25px], [16, 3px], [18, 5m]]
+                        color: [[8, [0.529,0.556,0.592]], [11, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                        width: [[10, 0.5px], [13, 0.5px], [14, 1px], [15, 0px], [16, 1.75px], [17, 2px], [18, 3px], [19, 8px]]
                         outline:
-                            color: [[11, [0.969,0.969,0.969]], [13, [0.969,0.969,0.969]], [14, [0.670,0.623,0.654]]]
-                            width: [[8, 0px], [9, 0px], [13, 0px], [14, 0.6px], [16, 1.25px], [18, 2px]]
-                early_link:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        lines:
-                            order: 351
+                            color: [[8,[0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                            width: [[10, 0px], [14, 0px], [15, 0.5px], [16, 1px], [17, 1px], [18, 1px]]
             tunnel:
-                filter: { is_tunnel: true, $zoom: { min: 13 } }
+                filter: {is_tunnel: true, $zoom: {min: 13} }
                 draw:
                     lines:
-                        color: [0.883,0.904,0.930]
+                        color: [[13,[0.779,0.802,0.828]], [14,[0.779,0.802,0.828]], [15,[0.744,0.764,0.792]], [16,[0.950,0.950,0.950]]]
                         outline:
-                            color: [0.640,0.703,0.780]
+                            color: [[13, [0.894,0.906,0.914]], [15, [0.894,0.906,0.914]], [16, [0.85,0.85,0.85]]]
+                            width: [[8,0px], [11,0px], [14,0px], [16,1.5px], [17, 3px], [18, 3px]]
             secondary:
                 filter: { kind_detail: secondary }
                 draw:
                     lines:
-                        color: [1.00,1.00,1.00]
-                        width: [[10, 0px], [11, 0px], [12, 1px], [14, 2px], [16, 4px], [17, 6px], [18, 9m]]
+                        color: [[10, [0.714,0.733,0.760]], [11, [0.714,0.733,0.760]], [12, [0.533,0.555,0.586]], [13, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                        width: [[10, 0.5px], [12, 0.5px], [13, 0.65px], [14, 1px], [15, 0px], [16, 3px], [17, 6px], [18, 9m]]
                         outline:
-                            color: [[9, [0.906,0.906,0.906]], [10, [0.788,0.780,0.800]], [11, [0.787,0.763,0.767]], [14, [0.700,0.665,0.688]]]
-                            width: [[10, 0px], [11, 0.5px], [12, 1px], [14, 1px], [16, 2.25px], [18, 4px]]
+                            color: [[10, [0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                            width: [[10,0px], [14,0px], [15,1px], [16, 1.5px], [17, 2px], [18, 4px]]
                 early:
-                    filter: { $zoom: { max: 14 } }
+                    filter: { $zoom: { max: 16 } }
                     draw:
                         lines:
                             order: 352
                             outline:
                                 order: 353 #function() { return feature.sort_rank + 2; }
-                    earlyz-13:
-                        filter: { $zoom: [13] }
-                        draw:
-                            lines:
-                                outline:
-                                    order: function() { return feature.sort_rank + 1; }
                 routes:
-                    filter: { ref: true, $zoom: { min: } }
+                    filter: { ref: true, $zoom: { min: 10} }
                     draw:
                         lines:
-                            color: [[10, [0.584,0.604,0.624]], [11, [1.00, 1.00, 1.00]]]
-                            width: [[8, 0px], [10, 0.7px], [11, 1px], [12, 1px], [14, 2px], [16, 4px], [18, 9m]]
+                            color: [[11, [0.508,0.530,0.561]], [13, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                            width: [[11, 0.4px], [12, 0.75px], [13, 0.75px], [14, 1px], [15, 0px], [16, 1.5px], [17, 6px], [18, 9m]]
                             outline:
-                                color: [[9, [0.906,0.906,0.906]], [10, [0.906,0.906,0.906]], [11, [0.787,0.763,0.767]], [14, [0.700,0.665,0.688]]]
-                                width: [[9, 0.25px], [10, 0.75px], [11, 0.75px], [12, 1px], [14, 1px], [16, 2.25px], [18, 4px]]
+                                color: [[10, [0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                                width: [[10,0.4px], [14,0.5px], [15,0.65px], [16,1.5px], [17, 2px], [18, 4px]]
                     early:
-                        filter: { $zoom: { max: 14 } }
+                        filter: { $zoom: { max: 15 } }
                         draw:
                             lines:
                                 order: function() { return feature.sort_rank + 2; }
                                 outline:
                                     order: 353
-                        # earlyz-13:
-                        #     filter: { $zoom: [13] }
-                        #     draw:
-                        #         lines:
-                        #             order: 352
-                        #             outline:
-                        #                 order: function() { return feature.sort_rank + 1; }
+                    secondary-route-in-green:
+                        filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield] }
+                        draw:
+                            lines:
+                                color: [[11, [0.408,0.430,0.461]], [13, [0.408,0.430,0.461]], [14, [0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                                width: [[11, 0.6px], [12, 0.75px], [13, 0.75px], [14, 1px], [15, 0px], [16, 1.5px], [17, 6px], [18, 9m]]
+                                outline:
+                                    width: [[10,0.5px], [14,0.5px], [15,0.65px], [16,1.5px], [17, 2px], [18, 4px]]
                     tunnel:
-                        filter: { is_tunnel: true, $zoom: { min: 13 } }
+                        filter: {is_tunnel: true, $zoom: {min: 13} }
                         draw:
                             lines:
-                                color: [0.929,0.929,0.929]
+                                color: [[13,[0.779,0.802,0.828]], [14,[0.779,0.802,0.828]], [15,[0.8,0.8,0.8]], [16,[0.85,0.85,0.85]], [17,[0.950,0.950,0.950]]]
                                 outline:
-                                    color: [0.695,0.739,0.790]
-                    labels-secondary-routes-z13-up:
+                                    color: [[13, [0.350,0.350,0.350]], [16, [0.350,0.350,0.350]], [17, [0.85,0.85,0.85]]]
+                                    width: [[10,0px], [17, 2px], [18, 2px]]
+                    labels-secondary-routes:
+                        filter: { $zoom: [13] }
+                        draw:
+                            text-blend-order:
+                                priority: 56
+                                visible: *text_visible_secondary_e
+                                font:
+                                    fill: [0.536,0.556,0.581]
+                                    size: 11px
+                                    stroke: { color: *text_stroke, width: 4 }
+                    labels-secondary-routes-z14:
+                        filter: { $zoom: [14] }
+                        draw:
+                            text-blend-order:
+                                priority: 56
+                                visible: *text_visible_secondary_e
+                                font:
+                                    fill: [0.536,0.556,0.581]
+                                    size: 11px
+                                    stroke: { color: *text_stroke, width: 4 }
+                    labels-secondary-routes-z15:
+                        filter: { $zoom: { min: 15 } }
+                        draw:
+                            text-blend-order:
+                                priority: 56
+                                visible: *text_visible_secondary_e
+                                font:
+                                    fill: [0.536,0.556,0.581]
+                                    weight: 600
+                                    size: 11px
+                                    stroke: { color: *text_stroke, width: 4 }
+                    labels-secondary-routes-z16:
+                        filter: { $zoom: { min: 16 } }
+                        draw:
+                            text-blend-order:
+                                priority: 56
+                                visible: *text_visible_secondary_e
+                                font:
+                                    fill: [0.536,0.556,0.581]
+                                    weight: 600
+                                    size: 12px
+                                    stroke: { color: [0.969,0.973,0.973], width: 4 }
+                secondary-in-green:
+                    filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield] }
+                    draw:
+                        lines:
+                            color: [[10, [0.714,0.733,0.760]], [11, [0.714,0.733,0.760]], [12, [0.533,0.555,0.586]], [13, [0.529,0.556,0.592]], [14, [0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                            outline:
+                                color: [[10, [0.894,0.906,0.914]], [14, [0.529,0.556,0.592]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                    labels-secondary-in-green-z13:
                         filter: { $zoom: { min: 13 } }
                         draw:
                             text-blend-order:
                                 priority: 56
-                                visible: global.text_visible_secondary_e
+                                visible: *text_visible_secondary_e
                                 font:
                                     fill: [0.536,0.556,0.581]
-                                    size: [[13, 11px], [15, 11px], [16, 12px]]
-                                    stroke: { color: [[13, global.text_stroke], [16, [0.969,0.973,0.973]]], width: 4px }
-                        z15-up:
-                            filter: { $zoom: { min: 15 } }
-                            draw:
-                                text-blend-order:
-                                    visible: global.text_visible_secondary
-                                    font:
-                                        weight: 600
-                labels-secondary:
+                                    stroke: { color: [0.843,0.961,0.914], width: 4 }
+                    labels-secondary-in-green-z17:
+                        filter: { $zoom: { min: 17 } }
+                        draw:
+                            text-blend-order:
+                                priority: 56
+                                visible: *text_visible_secondary_e
+                                font:
+                                    fill: [0.536,0.556,0.581]
+                                    stroke: { color: [1.00,1.00,1.00], width: 4 }
+                    # golf_course:
+                    #     filter: { landuse_kind: golf_course }
+                    #     draw:
+                    #         lines:
+                    #             outline:
+                    #                 color: [[10, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
+                    # zoo:
+                    #     filter: { landuse_kind: zoo }
+                    #     draw:
+                    #         lines:
+                    #             outline:
+                    #                 color: [[10, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
+                labels-secondary-z13:
+                    filter:
+                        $zoom: [13]
+                    draw:
+                        text-blend-order:
+                            priority: 56
+                            visible: *text_visible_secondary_e
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 9px
+                                stroke: { color: *text_stroke, width: 4 }
+                labels-secondary-z14:
+                    filter:
+                        $zoom: [14]
+                    draw:
+                        text-blend-order:
+                            priority: 56
+                            visible: *text_visible_secondary_e
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 9px
+                                stroke: { color: *text_stroke, width: 4 }
+                labels-secondary-z15:
                     filter:
-                        $zoom: { min: 13 }
+                        $zoom: [15]
+                    draw:
+                        text-blend-order:
+                            priority: 56
+                            visible: *text_visible_secondary
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 10px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
+                labels-secondary-z16:
+                    filter: { $zoom: { min: 16, max: 18 } }
+                    draw:
+                        text-blend-order:
+                            priority: 56
+                            visible: *text_visible_secondary
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 12px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
+                labels-secondary-z17:
+                    filter: { $zoom: { min: 17 } }
                     draw:
                         text-blend-order:
                             priority: 56
-                            visible: global.text_visible_secondary_e
+                            visible: *text_visible_secondary
                             font:
                                 fill: [0.536,0.556,0.581]
-                                size: [[13, 9px], [14, 9px], [15, 10px], [16, 12px], [17, 13px]]
-                                stroke: { color: [[13, global.text_stroke], [15, [0.969,0.973,0.973]]], width: 4px }
+                                size: 13px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
             tertiary:
                 filter: { kind_detail: [tertiary, tertiary_link] }
                 draw:
                     lines:
-                        color: [1.00, 1.00, 1.00]
-                        width: [[11, 0px], [12, 0px], [13, 1px], [14, 2px], [16, 3.5px], [17, 6px], [18, 9m]]
+                        color: [[11, [0.714,0.733,0.760]], [12, [0.633,0.655,0.686]], [13, [0.529,0.556,0.592]], [14,[0.529,0.556,0.592]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                        width: [[11, 0.5px], [12, 0.65px], [13, 0.65px], [14, 1px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
                         outline:
-                            color: [[11, [0.847,0.822,0.826]], [12, [0.797,0.770,0.775]], [14, [0.714,0.694,0.706]]]
-                            width: [[10, 0px], [11, 0px], [12, 0.3px], [14, 1px], [16, 2px], [17, 2px], [18, 4px]]
+                            color: [0.529,0.556,0.592]
+                            width: [[11, 0px], [14, 0px], [15, 0.75px], [16, 1.5px], [17, 2px], [18, 3px]]
                 early:
-                    filter: { $zoom: { max: 14 } }
+                    filter: { $zoom: { max: 15 } }
                     draw:
                         lines:
                             order: 352
                             outline:
                                 order: function() { return feature.sort_rank + 3; }
                 routes:
-                    filter: { ref: true, $zoom: { min: 12 } }
+                    filter: { ref: true, $zoom: { min: 12} }
                     draw:
                         lines:
-                            color: [1.00,1.00,1.00]
-                            width: [[11, 0px], [12, 1px], [14, 2px], [16, 3.5px], [17, 6px], [18, 9m]]
+                            color: [[11, [0.408,0.430,0.461]], [13, [0.408,0.430,0.461]], [14,[0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                            width: [[11, 0.3px], [12, 0.4px], [13, .6px], [14, 1px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
                             outline:
-                                color: [[11, [0.788,0.780,0.800]], [12, [0.797,0.770,0.775]]]
-                                width: [[11, 0.4px], [12, 1px], [14, 1px], [16, 2px], [17, 2px], [18, 4px]]
+                                color: [[11, [0.894,0.906,0.914]], [14,[0.779,0.802,0.828]], [15, [0.529,0.556,0.592]]]
+                                width: [[11, 0px], [14, 0px], [15, 0.75px], [16, 1.5px], [17, 2px], [18, 3px]]
                     early:
-                        filter: { $zoom: { max: 14 } }
+                        filter: { $zoom: { max: 15 } }
                         draw:
                             lines:
                                 order: function() { return feature.sort_rank + 3; }
                                 outline:
                                     order: 353
                     tunnel:
-                        filter: {is_tunnel: true, $zoom: { min: 13 } }
+                        filter: {is_tunnel: true, $zoom: {min: 13} }
                         draw:
                             lines:
-                                color: [0.929,0.929,0.929]
+                                color: *major_tunnel1
                                 outline:
-                                    color: global.major_tunnel_casing1
-                # this was needed in the past, but where is an example map location to debug now? hmm.
-                # link:
-                #     filter: { is_link: true } # on- and off-ramps, etc
-                #     draw:
-                #         lines:
-                #             color: [[14, [0.714,0.733,0.760]], [15, [0.578,0.608,0.650]], [16, [0.533,0.555,0.586]], [17, [1.00,1.00,1.00]]]
-                #             width: [[11, 0.0px], [12, 0.15px], [14, 0.15px], [15, 0.75px], [16, 1.25px], [17, 2px], [18, 2px], [19, 4px]]
-                #             outline:
-                #                 color: [[11, [1.00,1.00,1.00]], [16, [1.00,1.00,1.00]], [17,[0.578,0.608,0.650]]]
-                #                 width: [[11, 0px], [16, 0px], [17, 1px], [18, 1px]]
-                labels-tertiary:
-                    filter:
-                        $zoom: { min: 13 }
+                                    color: *major_tunnel_casing1
+                link:
+                    filter: { is_link: true } # on- and off-ramps, etc
+                    draw:
+                        lines:
+                            color: [[14, [0.714,0.733,0.760]], [15, [0.578,0.608,0.650]], [16, [0.533,0.555,0.586]], [17, [1.00,1.00,1.00]]]
+                            width: [[11, 0.0px], [12, 0.15px], [14, 0.15px], [15, 0.75px], [16, 1.25px], [17, 2px], [18, 2px], [19, 4px]]
+                            outline:
+                                color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17,[0.578,0.608,0.650]]]
+                                width: [[11, 0px], [16, 0px], [17, 1px], [18, 1px]]
+                tertiary-in-green:
+                    filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden,wood,national_park,protected_area,battlefield,forest] }
+                    draw:
+                        lines:
+                            color: [[11, [0.408,0.430,0.461]], [13, [0.408,0.430,0.461]], [14,[0.408,0.430,0.461]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                            width: [[11, 0.4px], [12, 0.5px], [13, 0.6px], [14, .8px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
+                            outline:
+                                color: [[11, [0.894,0.906,0.914]], [14,[0.779,0.802,0.828]], [15, [0.529,0.556,0.592]], [16, [0.529,0.556,0.592]], [17,[0.578,0.608,0.650]], [18,[0.714,0.733,0.760]]]
+                                width: [[10,0.5px], [14,0.5px], [15,0.65px], [16,1.5px], [17, 2px], [18, 4px]]
+                    green-routes:
+                        filter: { ref: true, $zoom: { min: 12} }
+                        draw:
+                            lines:
+                                width: [[11, 0.5px], [12, 0.6px], [13, 0.7px], [14, .9px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
+                    labels-tertiary-in-green-z13:
+                        filter: { $zoom: { min: 13 } }
+                        draw:
+                            text-blend-order:
+                                priority: 57
+                                visible: *text_visible_tertiary_e
+                                font:
+                                    fill: [0.536,0.556,0.581]
+                                    stroke: { color: [0.843,0.961,0.914], width: 4 }
+                    labels-tertiary-in-green-z17:
+                        filter: { $zoom: { min: 17 } }
+                        draw:
+                            text-blend-order:
+                                priority: 57
+                                visible: *text_visible_tertiary_e
+                                font:
+                                    fill: [0.536,0.556,0.581]
+                                    stroke: { color: [1.00,1.00,1.00], width: 4 }
+                    # golf_course:
+                    #     filter: { landuse_kind: golf_course }
+                    #     draw:
+                    #         lines:
+                    #             outline:
+                    #                 color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
+                    # zoo:
+                    #     filter: { landuse_kind: zoo }
+                    #     draw:
+                    #         lines:
+                    #             outline:
+                    #                 color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
+                labels-tertiary-z13:
+                    filter: { $zoom: [13] }
+                    draw:
+                        text-blend-order:
+                            priority: 57
+                            visible: *text_visible_tertiary_e
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 9px
+                                stroke: { color: *text_stroke, width: 4 }
+                labels-tertiary-z14:
+                    filter: { $zoom: [14] }
+                    draw:
+                        text-blend-order:
+                            priority: 57
+                            visible: *text_visible_tertiary_e
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 9px
+                                stroke: { color: *text_stroke, width: 4 }
+                labels-tertiary-z15:
+                    filter: { $zoom: [15] }
+                    draw:
+                        text-blend-order:
+                            priority: 57
+                            visible: *text_visible_tertiary
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 10px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
+                labels-tertiary-z16:
+                    filter: { $zoom: [16] }
+                    draw:
+                        text-blend-order:
+                            priority: 57
+                            visible: *text_visible_tertiary
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 12px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
+                labels-tertiary-z17:
+                    filter: { $zoom: { min: 17, max: 18 } }
+                    draw:
+                        text-blend-order:
+                            priority: 57
+                            visible: *text_visible_tertiary
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                size: 13px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
+                labels-tertiary-z18:
+                    filter: { $zoom: { min: 18 } }
                     draw:
                         text-blend-order:
                             priority: 57
-                            visible: global.text_visible_tertiary
+                            visible: *text_visible_tertiary
                             font:
                                 fill: [0.536,0.556,0.581]
-                                size: [[13, 9px], [15, 10px], [16, 12px], [17, 13px]]
-                                stroke: { color: [[13, global.text_stroke], [15, [0.969,0.973,0.973]]], width: 4px }
+                                size: 13px
+                                stroke: { color: [0.969,0.973,0.973], width: 4 }
         minor_road:
             filter: { kind: minor_road, not: { kind_detail: service } }
             draw:
                 lines:
-                    color: [1.00,1.00,1.00] #[[12, [0.850,0.850,0.850]], [13, [0.714,0.733,0.760]], [16, [1.00,1.00,1.00]]]
-                    width: [[11, 0px], [12, 0.5px], [13, 0.5px], [14, 1px], [16, 3px], [18, 9m]]
+                    color: [[11, [0.885,0.885,0.885]], [12, [0.714,0.733,0.760]], [13, [0.779,0.802,0.828]], [14, [0.779,0.802,0.828]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                    width: [[11, 0.25px], [12, 0.35px], [13, 0.55px], [14, 1px], [15, 0px], [16, 1px], [17, 6px], [18, 9m]]
                     outline:
-                        color: [[12, [0.900,0.900,0.900]], [13, [0.774,0.797,0.823]], [14, [0.798,0.823,0.847]]]
-                        width: [[11, 0px], [12, 0px], [13, 0px], [14, 1px], [16, 1.5px], [17, 2px], [18, 3px]]
+                        color: [[11, [0.894,0.906,0.914]], [14, [0.779,0.802,0.828]], [15, [0.714,0.733,0.760]], [16, [0.714,0.733,0.760]], [17, [0.744,0.764,0.792]]]
+                        width: [[11, 0px], [14, 0px], [15, 0.75px], [16, 1.5px], [17, 2px], [18, 3px]]
             early:
-                filter: { $zoom: { max: 14 } }
+                filter: { $zoom: { max: 16 } }
                 draw:
                     lines:
                         order: 350
@@ -1982,13 +2625,68 @@ layers:
                     lines:
                         cap: round
                         join: round
+
+            minor-in-green:
+                filter: { landuse_kind: [park,protected_area,nature_reserve,conservation,golf_course,garden,wood,farmland,farm,national_park,protected_area,battlefield] }
+                draw:
+                    lines:
+                        color: [[11, [0.885,0.885,0.885]], [12, [0.662,0.681,0.704]], [13, [0.662,0.681,0.704]], [14, [0.662,0.681,0.704]], [15, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]]]
+                        outline:
+                            color: [[11, [0.894,0.906,0.914]], [14, [0.662,0.681,0.704]], [15, [0.662,0.681,0.704]], [16, [0.662,0.681,0.704]]]
+                labels-minor-in-green-z15:
+                    filter: { $zoom: { min: 15 } }
+                    draw:
+                        text-blend-order:
+                            priority: 59
+                            visible: *text_visible_minor_road_e
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                stroke: { color: [0.843,0.961,0.914], width: 4 }
+                labels-minor-in-green-z17:
+                    filter: { $zoom: { min: 17 } }
+                    draw:
+                        text-blend-order:
+                            priority: 59
+                            visible: *text_visible_minor_road_e
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                stroke: { color: [1.00,1.00,1.00], width: 4 }
+            #     golf_course:
+            #         filter: { landuse_kind: golf_course }
+            #         draw:
+            #             lines:
+            #                 outline:
+            #                     color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.30,0.30,0.30]], [18, [0.00,0.00,0.00]]]
+            #     zoo:
+            #         filter: { landuse_kind: zoo }
+            #         draw:
+            #             lines:
+            #                 outline:
+            #                     color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.30,0.30,0.30]], [18, [0.00,0.00,0.00]]]
+            # in_university:
+            #     filter: { landuse_kind: university }
+            #     draw:
+            #         lines:
+            #             color: [[11, [0.885,0.885,0.885]], [13, [0.75,0.75,0.75]], [14, [0.70,0.70,0.70]], [15, [0.6,0.6,0.6]], [16, [0.3,0.3,0.3]], [17, [1.0,1.0,1.0]]]
+            #             outline:
+            #                 color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
+            #                 width: [[11, 1px], [16, 0px], [17, 1.5px]]
+            # in_hospital:
+            #     filter: { landuse_kind: hospital }
+            #     draw:
+            #         lines:
+            #             color: [[11, [0.885,0.885,0.885]], [13, [0.75,0.75,0.75]], [14, [0.70,0.70,0.70]], [15, [0.6,0.6,0.6]], [16, [0.3,0.3,0.3]], [17, [1.0,1.0,1.0]]]
+            #             outline:
+            #                 color: [[11, [1.0,1.0,1.0]], [16, [1.0,1.0,1.0]], [17, [0.00,0.00,0.00]]]
+            #                 width: [[11, 1px], [16, 0px], [17, 1.5px]]
+
             tunnel:
-                filter: { is_tunnel: true, $zoom: { min: 13 } }
+                filter: {is_tunnel: true, $zoom: {min: 13} }
                 draw:
                     lines:
-                        color: global.minor_tunnel1
+                        color: *minor_tunnel1
                         outline:
-                            color: global.minor_tunnel_casing1
+                            color: *minor_tunnel_casing1
             minor_road_bridge:
                 filter: { is_bridge: true }
                 draw:
@@ -1996,606 +2694,159 @@ layers:
                         cap: round
                         outline:
                             cap: butt
-            labels-minor_road:
-                filter:
-                    $zoom: { min: 15 }
+            labels-minor_road-z15:
+                filter: { $zoom: 15 }
+                draw:
+                    text-blend-order:
+                        priority: 59
+                        visible: *text_visible_minor_road_e
+                        font:
+                            fill: [0.536,0.556,0.581]
+                            size: 9px
+                            stroke: { color: *text_stroke, width: 4 }
+            labels-minor_road-z16:
+                filter: { $zoom: 16 }
                 draw:
                     text-blend-order:
                         priority: 59
-                        visible: global.text_visible_minor_road_e
+                        visible: *text_visible_minor_road_e
                         font:
-                            fill: [[15, [0.536,0.556,0.581]], [17, [0.40,0.40,0.40]]]
-                            size: [[15, 9px], [16, 12px], [17, 12px], [18, 13px]]
-                            stroke: { color: [[15, global.text_stroke], [17,[0.969,0.973,0.973]]], width: 4px }
-            early-residential:
-                filter: { kind_detail: residential, $zoom: { max: 15 } }
+                            fill: [0.536,0.556,0.581]
+                            size: 12px
+                            stroke: { color: *text_stroke, width: 4 }
+            labels-minor_road-z17:
+                filter: { $zoom: { min: 17, max: 18 } }
                 draw:
-                    lines:
-                        order: 350
-                        outline:
-                            order: 351
+                    text-blend-order:
+                        priority: 59
+                        visible: *text_visible_minor_road_e
+                        font:
+                            fill: [0.40,0.40,0.40]
+                            size: 12px
+                            stroke: { color: [0.969,0.973,0.973], width: 4 }
+            labels-minor_road-z18:
+                filter: { $zoom: { min: 18 } }
+                draw:
+                    text-blend-order:
+                        priority: 59
+                        visible: *text_visible_minor_road
+                        font:
+                            fill: [0.40,0.40,0.40]
+                            size: 13px
+                            stroke: { color: [0.969,0.973,0.973], width: 4 }
         service_road:
             filter: { kind: minor_road, kind_detail: service }
             draw:
                 lines:
-                    color: [1.00,1.00,1.00]
-                    width: [[14, 1px], [16, 2px], [18, 4m]]
+                    color: [[14, [0.714,0.733,0.760]], [15, [0.714,0.733,0.760]], [16, [1.0,1.0,1.0]], [17, [1.0,1.0,1.0]]]
+                    width: [[14, 0.25px], [15, 0.5px], [16, 0px], [17, 2px], [18, 6px], [19, 6px]]
                     outline:
-                        color: [[12, [0.900,0.900,0.900]], [14, [0.791,0.816,0.840]]]
-                        width: [[13, 0px], [14, 0.5px], [16, 1px], [18, 2px]]
-            early:
-                filter: { $zoom: { max: 15 } }
+                        color: [[14,[0.894,0.906,0.914]], [15,[0.714,0.733,0.760]], [16,[0.714,0.733,0.760]], [17, [0.791,0.812,0.842]]]
+                        width: [[13, 0px], [15, 0px], [16, 0.5px], [17, 2px], [18, 2px]]
+            service-in-green:
+                filter: { landuse_kind: [park,protected_area,nature_reserve,conservation,golf_course,garden,wood,farmland,farm,national_park,battlefield] }
                 draw:
                     lines:
-                        order: 350
+                        color: [[14, [0.779,0.802,0.828]], [15, [0.779,0.802,0.828]], [16, [1.0,1.0,1.0]], [17, [1.0,1.0,1.0]]]
                         outline:
-                            order: 351
+                            color: [[14,[0.894,0.906,0.914]], [15,[0.714,0.733,0.760]], [17,[0.714,0.733,0.760]]]
+                labels-service-in-green:
+                    draw:
+                        text-blend-order:
+                            priority: 60
+                            visible: *text_visible_service_road
+                            font:
+                                fill: [0.536,0.556,0.581]
+                                stroke: { color: [0.843,0.961,0.914], width: 4 }
+            #     golf_course:
+            #         filter: { landuse_kind: golf_course }
+            #         draw:
+            #             lines:
+            #                 outline:
+            #                     color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
+            #                     width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
+            #     nature_reserve:
+            #         filter: { landuse_kind: nature_reserve }
+            #         draw:
+            #             lines:
+            #                 outline:
+            #                     color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
+            #                     width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
+            #     conservation:
+            #         filter: { landuse_kind: conservation }
+            #         draw:
+            #             lines:
+            #                 outline:
+            #                     color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
+            #                     width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
+            #     zoo:
+            #         filter: { landuse_kind: zoo }
+            #         draw:
+            #             lines:
+            #                 outline:
+            #                     color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
+            #                     width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
+            in_cemetery_garden:
+                filter: { landuse_kind: [cemetery,garden] }
+                draw:
+                    lines:
+                        color: [[14, [0.779,0.802,0.828]], [15, [0.779,0.802,0.828]], [16, [1.0,1.0,1.0]], [17, [1.0,1.0,1.0]]]
+                        width: [[14, 0.4px], [15, 0.5px], [16, 0px], [17, 2px], [18, 6px], [19, 6px]]
+                        outline:
+                            color: [[14,[0.894,0.906,0.914]], [15,[0.714,0.733,0.760]], [17,[0.714,0.733,0.760]]]
+            # in_university:
+            #     filter: { landuse_kind: university }
+            #     draw:
+            #         lines:
+            #             outline:
+            #                 color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
+            #                 width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
+            # in_hospital:
+            #     filter: { landuse_kind: hospital }
+            #     draw:
+            #         lines:
+            #             outline:
+            #                 color: [[14,[1.0,1.0,1.0]], [16,[1.0,1.0,1.0]], [17,[0.30,0.30,0.30]], [18,[0.00,0.00,0.00]]]
+            #                 width: [[13, 0px], [14, 0.5px], [16, 0px], [17, 1.0px]]
             labels-service_road:
-                filter:
-                    $zoom: { min: 17 }
+                filter: { $zoom: 17 }
                 draw:
                     text-blend-order:
                         priority: 60
-                        visible: global.text_visible_service_road
+                        visible: *text_visible_service_road
                         font:
+                            # need fill color?
                             fill: [0.536,0.556,0.581]
-                            size: [[17, 12px], [18, 13px]]
-                            stroke: { color: [0.969,0.973,0.973], width: 4px }
-
+                            size: 12px
+                            stroke: { color: [0.969,0.973,0.973], width: 4 }
+            labels-service_road-z18:
+                filter: { $zoom: { min: 18 } }
+                draw:
+                    text-blend-order:
+                        priority: 60
+                        visible: *text_visible_service_road
+                        font:
+                            fill: [0.536,0.556,0.581]
+                            size: 13px
+                            stroke: { color: [0.969,0.973,0.973], width: 4 }
 
-        shields:
+        path:
             filter:
-                $zoom: { min: 6 }
-                #
-                # United State looks great with shield_text alone, but...
-                #
-                #shield_text: true    # some roads don't have shield text, deal with that later
-                #
-                # Europe doesn't have many network relations set, so we could look for either
-                # shield_text or ref (with no shield_text) but...
-                # that makes United States look a bit funky with `(xxx)` and generic shields
-                # showing up in fields of custom state shields like US:CA and US:NY
-                #
-                any:
-                    - shield_text: true    # some roads don't have shield text, deal with that later
-                    - all:
-                        - shield_text: false    # some roads don't have shield text, deal with that later
-                        - ref: true
-                        - kind_detail: [motorway, trunk, primary, secondary, tertiary]
-            # default
+                all:
+                    - kind: [path, portage_way]
+                not:
+                    - kind_detail: [footway, steps, track, cycleway]
+                    - kind_detail: [pier]
             draw:
-                icons:
-                    # you need to match any custom shield to the vector tile `network` values
-                    sprite: |
-                        function() {
-                            if( feature.shield_text ) {
-                                return ('generic_shield-' + feature.shield_text.length + 'char');
-                            } else {
-                                return ('generic_shield-' + feature.ref.length + 'char');
-                            }
-                        }
-                    sprite_default: generic_shield_5char
-                    priority: 58
-                    repeat_group: shields
-                    repeat_distance: [[8,90px],[10,40px],[13,30px]]
-                    placement: midpoint
-                    placement_min_length_ratio:
-                        - [8, 0.1]
-                        - [9, 0.25]
-                        - [10, 0.25]
-                        - [11, 0.15]
-                        - [12, 1]
-                        - [13, 1.50]
-                        - [14, 2.0]
-                    cull_from_tile: true
+                dashedline:
+                    order: function() { return feature.sort_rank; }
                     visible: false
-                    text:
-                        offset: [0px, -0.5px]
-                        repeat_distance: 200px
-                        anchor: center
-                        text_source: |
-                            function() {
-                                if( feature.shield_text ) {
-                                    return feature.shield_text;
-                                } else {
-                                    return feature.ref;
-                                }
-                            }
-                        font:
-                            family: Montserrat
-                            #fill: [0.308,0.308,0.308]
-                            fill: [0.320,0.320,0.320]
-                            size: [[7,7px],[12,8px],[16,11px]]
-
-            default_priority_highway:
-                filter:
-                    all:
-                        - kind_detail: motorway
-                        - $zoom: { min: 9 }
-                draw:
-                    icons:
-                        priority: 47
-                        #color: yellow
-                        visible: global.sdk_road_shields
-
-            default_priority_trunk:
-                filter:
-                    all:
-                        - kind_detail: [trunk]
-                        - $zoom: { min: 10 }
-                draw:
-                    icons:
-                        priority: 48
-                        #color: red
-                        visible: global.sdk_road_shields
-            default_priority_primary:
-                filter:
-                    all:
-                        - kind_detail: [primary]
-                        - $zoom: { min: 12 }
-                draw:
-                    icons:
-                        priority: 49
-                        #color: aqua
-                        visible: global.sdk_road_shields
-            default_priority_trunk_secondary:
-                filter:
-                    all:
-                        - kind_detail: [secondary]
-                        - $zoom: { min: 12 }
-                draw:
-                    icons:
-                        priority: 53
-                        #color: blue
-                        visible: global.sdk_road_shields
-            default_priority_trunk_tertiary:
-                filter:
-                    all:
-                        - kind_detail: tertiary
-                        - $zoom: { min: 13 }
-                draw:
-                    icons:
-                        priority: 55
-                        #color: green
-                        visible: global.sdk_road_shields
-            # not-special:
-            #     filter:
-            #         not: { network: ['US:I','US:US'] }
-            #         $zoom: { max: 9 }
-            #     draw:
-            #         icons:
-            #             visible: false
-            width_1char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 1)
-                        } else {
-                            return (feature.ref.length === 1)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[14px,14px]],[13,[16px,16px]],[16,[18px,18px]]]
-            width_2char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 2)
-                        } else {
-                            return (feature.ref.length === 2)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[18px,14px]],[13,[20px,15px]],[16,[24px,18px]]]
-            width_3char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 3)
-                        } else {
-                            return (feature.ref.length === 3)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[25px,14px]],[13,[27px,15px]],[16,[33px,18px]]]
-            width_4char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 4)
-                        } else {
-                            return (feature.ref.length === 4)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[29px,14px]],[13,[31px,15px]],[16,[38px,18px]]]
-                # London sucks
-                early:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        icons:
-                            visible: false
-            width_5char:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length === 5)
-                        } else {
-                            return (feature.ref.length === 5)
-                        }
-                    }
-                draw:
-                    icons:
-                        size: [[6,[34px,14px]],[13,[37px,15px]],[16,[45px,18px]]]
-                # London sucks
-                early:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        icons:
-                            visible: false
-            # this is kinda a hack
-            width_longggggg:
-                filter: |
-                    function() {
-                        if( feature.shield_text ) {
-                            return (feature.shield_text.length > 5)
-                        } else {
-                            return (feature.ref.length > 5)
-                        }
-                    }
-                draw:
-                    icons:
-                        visible: false
-            # missing-route-relations:
-            #     filter: { shield_text: false }
-            #     draw:
-            #         lines:
-            #             order: 1000
-            #             color: red
-            #             width: 2px
-            #
-            # Now for the good stuff
-            #
-            legit-shields:
-                filter: { shield_text: true }
-                # draw:
-                #     icons:
-                #         color: red
-                # US Interstate roads
-                US-I:
-                    filter:
-                        network: 'US:I'
-                    draw:
-                        icons:
-                            # you need to match any custom shield to the vector tile `network` values
-                            sprite: function() { return (feature.network + '-' + feature.shield_text.length + 'char'); }
-                            priority: 46
-                            visible: global.sdk_road_shields
-                            text:
-                                offset: [0px, 0.5px]
-                                font:
-                                    fill: [1.0,1.0,1.0]
-                                    size: [[7,8px],[13,9px],[15,11px]]
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[15px,18px]],[13,[17px,20px]],[15,[22px,25px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[18px,18px]],[13,[20px,20px]],[15,[25px,25px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[23px,18px]],[13,[26px,20px]],[15,[33px,25px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[25px,18px]],[13,[27px,20px]],[15,[35px,25px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[26px,18px]],[13,[30px,20px]],[15,[38px,25px]]]
-                # US Federal Routes
-                US-US:
-                    filter:
-                        network: ['US:US','US:US:Business', 'US:US:Truck', 'US:US:Alternate']
-                        $zoom: { min: 7 }
-                    draw:
-                        icons:
-                            # you need to match any custom shield to the vector tile `network` values
-                            sprite: |
-                                function() { return ('US:US-' + feature.shield_text.length + 'char'); }
-                            priority: 47
-                            cull_from_tile: true
-                            visible: global.sdk_road_shields
-                            text:
-                                offset: [0px, -0.7px]
-                                font:
-                                    fill: [0.0,0.0,0.0]
-                                    size: [[7,8px],[13,9px],[15,11px]]
-                    # early:
-                    #     filter: { $zoom: [7] }
-                    #     icons:
-                    #         visible: false
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[15px,17px]],[13,[17px,19px]],[15,[22px,24px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[18px,17px]],[13,[20px,19px]],[15,[26px,24px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[22px,17px]],[13,[25px,19px]],[15,[34px,25px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[25px,17px]],[13,[29px,19px]],[15,[39px,25px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[27px,17px]],[13,[30px,19px]],[15,[41px,25px]]]
-                # US State Routes
-                # US-states:
-                #     # Match state highways: `US:??`
-                #     filter: |
-                #         function() {
-                #             return feature.shield_text &&
-                #                 /^US:(?!US)\w\w$/.test(feature.network)
-                #         }
-                #     draw:
-                #         icons:
-                #             # you need to match any custom shield to the vector tile `network` values
-                #             priority: 18
-                #     early:
-                #         filter: { $zoom: [7,8,9] }
-                #         icons:
-                #             visible: false
-                US-CA:
-                    # Match California state highways: `US:CA`
-                    filter: |
-                        function() {
-                            return feature.shield_text &&
-                                /^US:CA$/.test(feature.network)
-                        }
-                    draw:
-                        icons:
-                            sprite: function() { return (feature.network + '-' + feature.shield_text.length + 'char'); }
-                            text:
-                                offset: [0px, 1px]
-                                font:
-                                    fill: [1.0,1.0,1.0]
-                                    size: [[7,7px],[13,9px],[15,10px]]
-                    motorway:
-                        filter: { kind_detail: [motorway], $zoom: [7,8] }
-                        draw:
-                            icons:
-                                visible: global.sdk_road_shields
-                    trunk:
-                        filter: { kind_detail: [trunk], $zoom: [8,9] }
-                        draw:
-                            icons:
-                                visible: global.sdk_road_shields
-                    primary:
-                        filter: { kind_detail: primary, $zoom: [10,11] }
-                        draw:
-                            icons:
-                                visible: global.sdk_road_shields
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[14px,16px]],[13,[15px,18px]],[15,[18px,21px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[18px,18px]],[13,[20px,20px]],[15,[23px,23px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[21px,18px]],[13,[24px,20px]],[15,[28px,23px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[24px,18px]],[13,[26px,20px]],[15,[31px,23px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[25px,18px]],[13,[27px,20px]],[15,[32px,23px]]]
-                US-NY:
-                    # Match New York state highways: `US:NY`
-                    filter: |
-                        function() {
-                            return feature.shield_text &&
-                                /^US:NY$/.test(feature.network)
-                                /* (/^US:NY$/.test(feature.network) || /^NY:US$/.test(feature.network)) */
-                        }
-                    draw:
-                        icons:
-                            sprite: |
-                                function() { return ( 'US:NY-' + feature.shield_text.length + 'char'); }
-                            text:
-                                # offset: [0px, 1px]
-                                font:
-                                    fill: [0.0,0.0,0.0]
-                                    size: [[7,7px],[13,9px],[15,10px]]
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[13px,17px]],[13,[15px,19px]],[15,[18px,22px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[17px,17px]],[13,[19px,19px]],[15,[22px,22px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[20px,17px]],[13,[22px,19px]],[15,[27px,22px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[21px,17px]],[13,[24px,19px]],[15,[29px,22px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[22px,17px]],[13,[25px,19px]],[15,[30px,22px]]]
-                US-PA:
-                    # Match Pennsylvania state highways
-                    filter: |
-                        function() {
-                            return feature.shield_text &&
-                                /^US:PA$/.test(feature.network)
-                        }
-                    draw:
-                        icons:
-                            sprite: |
-                                function() { return ( 'US:PA-' + feature.shield_text.length + 'char'); }
-                            text:
-                                offset: [0px, 1px]
-                                font:
-                                    fill: [0.0,0.0,0.0]
-                                    size: [[7,7px],[13,9px],[15,10px]]
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[13px,17px]],[13,[15px,19px]],[15,[18px,22px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[17px,17px]],[13,[19px,19px]],[15,[22px,22px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[21px,17px]],[13,[24px,19px]],[15,[28px,22px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[22px,17px]],[13,[25px,19px]],[15,[30x,22px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[24px,17px]],[13,[27px,19px]],[15,[32px,22px]]]
-                # USA County Routes
-                US-counties:
-                    # Match state highways: `US:??:*`
-                    #
-                    # this is very USA specific
-                    #
-                    # filter: |
-                    #     function() {
-                    #         return feature.shield_text &&
-                    #             /^US:(?!US)\w\w:.*$/.test(feature.network)
-                    #     }
-                    #
-                    # this generic for any country with 3rd level networks (like county routes in USA)
-                    # BEWARE:
-                    # US:US:Business  about 150
-                    # US:US:Truck
-                    # US:US:Alternate
-    #
-                    # STATE ROUTE
-                    # ??:??:Loop  about 200
-                    # ??:??:Spur  about 200
-                    # ??:??:Business   about 100
-    #
-                    # STATE TEXAS SPECIAL ROUTE
-                    # US:TX:FM -- probably just state? there are 3k of these
-                    #
-                    #
-                    filter: |
-                        function() {
-                            return feature.shield_text &&
-                                /^\w+:\w+:(!Alternate).+$/.test(feature.network) &&
-                                $zoom > 10
-                        }
-                    draw:
-                        icons:
-                            # you need to match any custom shield to the vector tile `network` values
-                            sprite: function() { return ('county_shield-' + feature.shield_text.length + 'char'); }
-                            # priority: 19
-                            visible: global.sdk_road_shields
-                            text:
-                                font:
-                                    fill: [0.320,0.320,0.320]
-                                    #size: [[11,7px],[15,10px]]
-                    # early:
-                    #     filter: { $zoom: { max: 11 } }
-                    #     draw:
-                    #         icons:
-                    #             visible: false
-                    width_1char:
-                        filter: function() { return (feature.shield_text.length === 1) }
-                        draw:
-                            icons:
-                                size: [[6,[14px,14px]],[13,[16px,16px]],[15,[18px,18px]]]
-                    width_2char:
-                        filter: function() { return (feature.shield_text.length === 2) }
-                        draw:
-                            icons:
-                                size: [[6,[16px,14px]],[13,[18px,15px]],[15,[22px,18px]]]
-                    width_3char:
-                        filter: function() { return (feature.shield_text.length === 3) }
-                        draw:
-                            icons:
-                                size: [[6,[20px,14px]],[13,[21px,15px]],[15,[26px,18px]]]
-                    width_4char:
-                        filter: function() { return (feature.shield_text.length === 4) }
-                        draw:
-                            icons:
-                                size: [[6,[25px,14px]],[13,[28px,15px]],[15,[34px,18px]]]
-                    width_5char:
-                        filter: function() { return (feature.shield_text.length === 5) }
-                        draw:
-                            icons:
-                                size: [[6,[30px,14px]],[13,[33px,15px]],[15,[40px,18px]]]
-        path:
-            filter:
-                all:
-                    - kind: [path, portage_way]
-                not:
-                    - kind_detail: [footway, steps, track, cycleway]
-                    - kind_detail: [pier]
-            draw:
-                dashed_small:
-                    order: function() { return feature.sort_rank; }
-                    visible: false
-                    color: [0.350,0.350,0.350]
-                    width: [[14, 0.35px], [15, 0.5px], [16, 1px], [17, 2px], [18, 3px], [19, 4px]]
-                    # outline:
-                    #     color: [0.790,0.790,0.790]
-                    #     width: [[14, 0.0px], [15, 0.35px], [16, 0.45px], [17, 0.85px], [18, 1px]]
-            early:
+                    color: [0.350,0.350,0.350]
+                    width: [[14, 0.35px], [15, 0.5px], [16, 1px], [17, 2px], [18, 3px], [19, 4px]]
+                    # outline:
+                    #     color: [0.790,0.790,0.790]
+                    #     width: [[14, 0.0px], [15, 0.35px], [16, 0.45px], [17, 0.85px], [18, 1px]]
+            early:
                 filter:
                     $zoom: { max: 17 }
                 draw:
@@ -2624,13 +2875,13 @@ layers:
                         width: [[14, 0.35px], [15, 0px], [16, 0.25px], [17, 3px], [18, 3px], [19, 4px]]
                         cap: round
                         outline:
-                            color: [[15, global.path_bridge_casing2],[16, global.path_bridge_casing1]]
+                            color: [[15,*path_bridge_casing2],[16,*path_bridge_casing1]]
                             width: [[14, 0.0px], [15, 0.35px], [16, 0.45px], [17, 0.85px], [18, 1px]]
                             cap: butt
             in_park:
                 filter: { landuse_kind: [park,nature_reserve,conservation,golf_course,garden] }
                 draw:
-                    dashed_small:
+                    dashedline:
                         color: [0.350,0.350,0.350]
                         # outline:
                         #     color: [0.790,0.790,0.790]
@@ -2700,11 +2951,11 @@ layers:
                 draw:
                     text-blend-order:
                         priority: 61
-                        visible: global.text_visible_path
+                        visible: *text_visible_path
                         font:
                             fill: [0.536,0.556,0.581]
                             size: 12px
-                            stroke: { color: global.text_stroke, width: 4 }
+                            stroke: { color: *text_stroke, width: 4 }
         track:
             filter: { kind: path, kind_detail: track }
             draw:
@@ -2806,14 +3057,14 @@ layers:
             #     filter: { landuse_kind: university }
             #     draw:
             #         dashed:
-            #             color: global.path_steps1_b
+            #             color: *path_steps1_b
             #             outline:
             #                 color: [1.0,1.0,1.0]
             # in_hospital:
             #     filter: { landuse_kind: hospital }
             #     draw:
             #         dashed:
-            #             color: global.path_steps1_b
+            #             color: *path_steps1_b
             #             outline:
             #                 color: [1.0,1.0,1.0]
             labels-steps:
@@ -2821,11 +3072,11 @@ layers:
                 draw:
                     text-blend-order:
                         priority: 63
-                        visible: global.text_visible_steps
+                        visible: *text_visible_steps
                         font:
                             fill: [0.45,0.45,0.45]
                             size: 11px
-                            stroke: { color: global.text_stroke, width: 4 }
+                            stroke: { color: *text_stroke, width: 4 }
         winter_sport_pistes:
             filter: { kind: piste }
             draw:
@@ -2837,9 +3088,9 @@ layers:
                     width: [[13,0px],[14,1px],[15, 1.25px], [16, 2px], [18, 3m]]
                 text-blend-order:
                     priority: 18
-                    visible: global.text_visible_piste
+                    visible: *text_visible_piste
                     font:
-                        fill: global.text_fill_piste
+                        fill: *text_fill_piste
                         size: 12px
                         stroke: { color: [0.913,0.925,0.933], width: 4 }
             early:
@@ -2852,7 +3103,7 @@ layers:
                 draw:
                     text-blend-order:
                         font:
-                            fill: global.text_fill_piste_e
+                            fill: *text_fill_piste_e
                             size: 11px
             easy:
                 filter: { piste_difficulty: easy }
@@ -2972,12 +3223,12 @@ layers:
                 draw:
                     text-blend-order:
                         priority: 63
-                        visible: global.text_visible_aerialway
+                        visible: *text_visible_aerialway
                         text_source: global.ux_language_text_source
                         font:
-                            fill: global.text_fill
+                            fill: *text_fill
                             size: 10px
-                            stroke: { color: global.text_stroke_park, width: 4 }
+                            stroke: { color: *text_stroke_park, width: 4 }
                 minor:
                     filter: { not: { kind_detail: [gondola,cable_car,chair_lift] }, $zoom: { max: 17 } }
                     draw:
@@ -3041,7 +3292,7 @@ layers:
             extrude:
                 filter:
                     all:
-                        - function() { return global.sdk_building_extrude; }
+                        - function() { return global.building_extrude; }
                         - any:
                             # for the buildings that were visible at zoom 15, extrude those all up a bit at z17
                             - { $zoom: [16], area: { min: 20000 }, name: true }
@@ -3095,17 +3346,72 @@ layers:
                         lines:
                             extrude: 100
 
+
+        # landuse-specific rules
+        # in_park:
+        #     filter: { landuse_kind: [park,forest,nature_reserve,conservation,golf_course,garden] }
+        #     draw:
+        #         polygons:
+        #             color: [0.864,0.910,0.905]
+
+        #     # golf_course:
+        #     #     filter: { landuse_kind: golf_course }
+        #     #     draw:
+        #     #         polygons:
+        #     #             color: *building2
+        #     # nature_reserve:
+        #     #     filter: { landuse_kind: nature_reserve }
+        #     #     draw:
+        #     #         polygons:
+        #     #             color: *building2
+        #     # conservation:
+        #     #     filter: { landuse_kind: conservation }
+        #     #     draw:
+        #     #         polygons:
+        #     #             color: *building2
+        #     # zoo:
+        #     #     filter: { landuse_kind: zoo }
+        #     #     draw:
+        #     #         polygons:
+        #     #             color: *building2
+        # in_university:
+        #     filter: { landuse_kind: [university,school] }
+        #     draw:
+        #         polygons:
+        #             color: [0.950,0.917,0.883]
+        #         lines:
+        #             color: *brown1_bo
+        # in_hospital:
+        #     filter: { landuse_kind: hospital }
+        #     draw:
+        #         polygons:
+        #             color: [0.976,0.908,0.913]
+        # in_airport:
+        #     filter: { landuse_kind: [aerodrome, runway, taxiway] }
+        #     draw:
+        #         polygons:
+        #             color: *purple_b
+        #         lines:
+        #             color: *purple_bo
+        #             width: [[14,0.5px],[15,0.5px],[17,0.5px],[18,0.75px],[19,0.25m]]
+        # in_retail:
+        #    filter: { landuse_kind: retail }
+        #    draw:
+        #         polygons:
+        #             color: [0.945, 0.898, 0.878]
+
         transit-overlay-station-buildings:
             filter:
-                all:
+                any:
                     - landuse_kind: [station]
-                    - function() { return global.sdk_transit_overlay; }
             draw:
                 polygons:
+                    visible: global.sdk_transit_overlay
                     color: '#bdadbf'
                     order: 500
                     #extrude: function() { return feature.height || 20; }
                 outline:
+                    visible: global.sdk_transit_overlay
                     style: lines
                     order: 501
                     color: '#d534df'
@@ -3119,7 +3425,6 @@ layers:
                     - $geometry: point
                     - not: { location: underground, kind: address }
                     - name: true
-                    - function() { return global.text_visible_building; }
                 any:
                     - { $zoom: [16], area: { min: 5000 } }
                     - { $zoom: [16], area: { min: 5000 } }
@@ -3136,16 +3441,17 @@ layers:
             draw:
                 text-blend-order:
                     text_source: global.ux_language_text_source
-                    #interactive: global.interactive
+                    interactive: global.interactive
                     move_into_tile: true
                     priority: 70
+                    visible: *text_visible_building
                     order: 7
                     font:
                         fill: '#666'
-                        family: global.text_font_family
+                        family: *text_font_family
                         style: italic
                         size: 11px
-                        stroke: { color: global.text_stroke_address, width: 1 }
+                        stroke: { color: *text_stroke_address, width: 1 }
             building_labels-z15-z16-z17:
                 filter: { $zoom: [15,16,17] }
                 draw: { text-blend-order: { font: { size: 12px, stroke: { width: 2 } } } }
@@ -3172,23 +3478,22 @@ layers:
                         text_source: global.ux_language_text_source_building_and_address
         address-labels:
             filter:
-                all:
-                    - $zoom: { min: 20 }
-                    - function() { return global.text_visible_address; }
+                $zoom: { min: 20 }
                 any:
                     - kind: address
                     - { label_position: true, addr_housenumber: true, name: false }
             draw:
                 text-blend-order:
-                    #interactive: global.interactive
+                    interactive: global.interactive
                     order: 7
+                    visible: *text_visible_address
                     text_source: addr_housenumber
                     font:
-                        fill: global.text_fill_address
-                        family: global.text_font_family
+                        fill: *text_fill_address
+                        family: *text_font_family
                         style: italic
                         size: 10px
-                        stroke: { color: global.text_stroke_address, width: 4 }
+                        stroke: { color: *text_stroke_address, width: 4 }
 
     boundaries:
         data: { source: mapzen, layer: boundaries }
@@ -3201,7 +3506,7 @@ layers:
                 - admin_level: 2
             draw:
                 lines:
-                    color: global.country_boundary
+                    color: *country_boundary
                     width: [[1, 0.5px], [2, 1.0px], [4, 1.5px], [9, 2.5px], [14, 3.5px], [16, 4.5px], [17, 14m]]
             water:
                 filter: { maritime_boundary: true }
@@ -3213,11 +3518,11 @@ layers:
                 draw:
                     text-blend-order:
                         priority: 2
-                        visible: global.text_visible_admin
+                        visible: *text_visible_admin
                         text_source: global.ux_language_text_source_boundary_lines
                         text_wrap: 100
                         font:
-                            family: global.text_font_family
+                            family: *text_font_family
                             size: 9px
                             fill: [0.00,0.00,0.00]
                             transform: uppercase
@@ -3227,7 +3532,7 @@ layers:
             draw:
                 dashed:
                     order: function() { return (feature.sort_rank + 100); }
-                    color: global.country_boundary
+                    color: *country_boundary
                     width: [[1,0.2px],[9,1.5px],[17,10m]]
             disputed:
                 filter: { kind: [disputed, line_of_control] }
@@ -3236,7 +3541,7 @@ layers:
                         visible: false
                     dashed_big:
                         order: function() { return (feature.sort_rank + 100); }
-                        color: global.country_boundary
+                        color: *country_boundary
                         width: [[1,0.5px],[9,2.5px],[17,14m]]
 
         region:
@@ -3245,7 +3550,7 @@ layers:
                 - kind_detail: [3,4]
             draw:
                 lines:
-                    color: global.region_boundary
+                    color: *region_boundary
                     width: [[0, 0.5px], [2, 1.0px], [5, 1.25px], [6, 1.5px], [7, 1.75px], [9, 2.0px], [14, 4.0px], [16, 5.0px], [17, 10m]]
             water:
                 filter: { maritime_boundary: true }
@@ -3262,13 +3567,13 @@ layers:
                 draw:
                     text-blend-order:
                         priority: 3
-                        visible: global.text_visible_admin
+                        visible: *text_visible_admin
                         text_source: global.ux_language_text_source_boundary_lines
                         text_wrap: 100
                         #offset: [0px, -7px]
                         anchor: top
                         font:
-                            family: global.text_font_family
+                            family: *text_font_family
                             size: 9px
                             fill: [0.35,0.35,0.35]
                             transform: uppercase
@@ -3276,19 +3581,19 @@ layers:
             filter: { kind: city_wall }
             draw:
                 lines:
-                    color: global.city_wall
+                    color: *city_wall
                     width: [[12, 0.75px], [13, 1.0px], [14, 1.2px], [15, 2.0px], [16, 2.5px], [19, 6m]]
         retaining_wall:
             filter: { kind: retaining_wall }
             draw:
                 lines:
-                    color: global.retaining_wall
+                    color: *retaining_wall
                     width: [[14, 0.5px], [15, 1.0px], [16, 1.5px], [17, 2.0px], [19, 4m]]
         snow_fence:
             filter: { kind: snow_fence }
             draw:
                 lines:
-                    color: global.snow_fence
+                    color: *snow_fence
                     width: [[14, 0.5px], [15, 1.0px], [16, 1.5px], [17, 2.0px], [19, 1.5m]]
         fence:
             filter: { kind: fence }
@@ -3300,7 +3605,7 @@ layers:
             filter: { kind: dam }
             draw:
                 lines:
-                    color: global.dam
+                    color: *dam
                     width: [[14, 0.5px], [15, 1.0px], [16, 1.5px], [17, 2.0px], [19, 1.5m]]
 
     places:
@@ -3314,16 +3619,16 @@ layers:
                     visible: false
                     buffer: 3px
                     font:
-                        family: global.text_font_family
-                        fill: global.text_fill
+                        family: *text_font_family
+                        fill: *text_fill
             # NOTE: This is a hack for localities because of an icon & text bug, see note below
             text-blend-order:
                 text_source: global.ux_language_text_source
                 visible: false    # labels are enabled by each layer below
                 buffer: 3px
                 font:
-                    family: global.text_font_family
-                    fill: global.text_fill
+                    family: *text_font_family
+                    fill: *text_fill
             # END NOTE
 
         country:
@@ -3333,19 +3638,19 @@ layers:
             draw:
                 text-blend-order:
                     priority: 3
-                    visible: global.text_visible_admin
+                    visible: *text_visible_admin
                     font:
-                        fill: global.text_fill
+                        fill: *text_fill
                         weight: 600
-                        stroke: { color: global.text_stroke, width: 4 }
+                        stroke: { color: *text_stroke, width: 4 }
             country-z2-3:
                 filter:
                     $zoom: [2,3]
                 draw:
                     text-blend-order:
-                        priority: 10
-                        buffer: 10px
                         font:
+                            priority: 10
+                            buffer: 10px
                             weight: 200
                             size: 11px
                 early-ones-z2:
@@ -3452,30 +3757,30 @@ layers:
                     not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
                 draw:
                     text-blend-order:
-                        visible: global.text_visible_admin
+                        visible: *text_visible_admin
                         text_source: global.ux_language_text_source_short
                         font:
                             fill: [0.70,0.70,0.70]
-                            stroke: { color: global.text_stroke, width: 4 }
+                            stroke: { color: *text_stroke, width: 4 }
             region-z5:
                 filter:
                     $zoom: [5]
                     not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
                 draw:
                     text-blend-order:
-                        visible: global.text_visible_admin
+                        visible: *text_visible_admin
                         text_source: global.ux_language_text_source_short
                         font:
                             size: 18px
                             weight: 200
-                            stroke: { color: global.text_stroke, width: 4 }
+                            stroke: { color: *text_stroke, width: 4 }
             region-z6:
                 filter:
                     $zoom: [6]
                     not: { name: [Western Cape,Eastern Cape,Northern Cape,North West,Limpopo,KwaZulu-Natal,Hamburg,Freie und Hansestadt Hamburg,Neuchâtel,Nordrhein-Westfalen,Haute-Normandie,Baden-Württemberg,Bayern,Sachsen-Anhalt,Berlin,Mecklenburg-Vorpommern,Schleswig-Holstein,Brandenburg,Niedersachsen,Saarland,Thüringen,Hessen,Sachsen] }
                 draw:
                     text-blend-order:
-                        visible: global.text_visible_admin
+                        visible: *text_visible_admin
                         text_source: global.ux_language_text_source_short
                         font:
                             size: 21px
@@ -3483,10 +3788,10 @@ layers:
                             transform: uppercase
 
             region-z7-z8:
-                filter: { $zoom: [7] }
+                filter: { $zoom: [7,8] }
                 draw:
                     text-blend-order:
-                        visible: global.text_visible_admin
+                        visible: *text_visible_admin
                         text_source: global.ux_language_text_source_short_proxy_name
                         font:
                             size: 30px
@@ -3530,23 +3835,23 @@ layers:
                 kind: locality
             draw:
                 icons:
-                    visible: global.icon_visible_populated_places
+                    visible: *icon_visible_populated_places
                     size: [[10,4px],[11,0px]]
                     sprite: townspot-xs-rev
                     buffer: 8px
                     priority: 30
                     text:
-                        visible: global.text_visible_populated_places
+                        visible: *text_visible_populated_places
                         buffer: 3px
                         font:
                             size: [[5,9px],[8,10px],[12,11px]]
-                            stroke: { color: global.text_stroke, width: 4 }
+                            stroke: { color: *text_stroke, width: 4 }
                 text-blend-order:
-                    visible: global.text_visible_populated_places
+                    visible: *text_visible_populated_places
                     buffer: 10px
                     font:
                         size: [[5,9px],[8,10px],[12,11px]]
-                        stroke: { color: global.text_stroke, width: 4 }
+                        stroke: { color: *text_stroke, width: 4 }
 
             #
             # NOTE: you'd think no-townspot would be the way to go, but icons with size 0px seems to have a bug to also hide the text :(
@@ -3567,7 +3872,7 @@ layers:
                     icons:
                         visible: false
                     text-blend-order:
-                        visible: global.text_visible_populated_places
+                        visible: *text_visible_populated_places
 
             _text_early:
                 filter: { $zoom: { max: 11 } }
@@ -3649,7 +3954,7 @@ layers:
                     text-blend-order:
                         priority: 6
                         font:
-                            size: [[2,11px],[6,17px],[8,19px],[12,21px],[13,0px]]
+                            size: [[2,11px],[6,17px],[8,19px],[12,21x],[13,0px]]
                 capital:
                     filter: { country_capital: true, $zoom: { min: 5 } }
                     draw:
@@ -3739,6 +4044,7 @@ layers:
                         size: [[8,6px],[9,6px],[10,6px],[11,0px]]
                         sprite: townspot-m-rev
                         priority: 13
+                        collide: false  #debug
                         text:
                             font:
                                 size: [[6,10px],[8,14px],[10,15px],[12,16px],[13,0px]]
@@ -3988,7 +4294,7 @@ layers:
                 draw:
                     text-blend-order:
                         text_wrap: 10
-                        visible: global.text_visible_neighbourhoods_e
+                        visible: *text_visible_neighbourhoods_e
                         font:
                             size: 9px
             neighborhood-z12:
@@ -4000,7 +4306,7 @@ layers:
                 draw:
                     text-blend-order:
                         text_wrap: 10
-                        visible: global.text_visible_neighbourhoods_e
+                        visible: *text_visible_neighbourhoods_e
                         font:
                             size: 10px
             neighborhood-z13:
@@ -4012,7 +4318,7 @@ layers:
                 draw:
                     text-blend-order:
                         text_wrap: 10
-                        visible: global.text_visible_neighbourhoods_e
+                        visible: *text_visible_neighbourhoods_e
                         font:
                             size: 12px
                             weight: 300
@@ -4027,7 +4333,7 @@ layers:
                 draw:
                     text-blend-order:
                         text_wrap: 12
-                        visible: global.text_visible_neighbourhoods
+                        visible: *text_visible_neighbourhoods
                         font:
                             size: 16px
                             weight: 300
@@ -4042,7 +4348,7 @@ layers:
                 draw:
                     text-blend-order:
                         text_wrap: 12
-                        visible: global.text_visible_neighbourhoods
+                        visible: *text_visible_neighbourhoods
                         font:
                             size: 21px
                             weight: 300
@@ -4065,7 +4371,7 @@ layers:
                     kind_tile_rank: { max: 8 }
                 draw:
                     text-blend-order:
-                        visible: global.text_visible_neighbourhoods
+                        visible: *text_visible_neighbourhoods
                         font:
                             size: 24px
                             weight: 300
@@ -4080,14 +4386,14 @@ layers:
             icons:
                 visible: false
             text-blend-order:
-                visible: global.text_visible_exits
+                visible: *text_visible_exits
                 interactive: global.interactive
                 text_source: ref
                 priority: 52
                 font:
-                    fill: global.text_fill_exits
+                    fill: *text_fill_exits
                     size: [[12,9px],[15,12px],[17,14px]]
-                    stroke: { color: global.text_stroke, width: [[12,2px],[14,3px],[15,3px]] }
+                    stroke: { color: *text_stroke, width: [[12,2px],[14,3px],[15,3px]] }
         later:
             filter: { $zoom: { min: 16 } }
             draw:
@@ -4101,13 +4407,13 @@ layers:
             icons:
                 visible: false
             text-blend-order:
-                visible: global.text_visible_airport_gate
+                visible: *text_visible_airport_gate
                 interactive: global.interactive
                 text_source: ref
                 font:
-                    fill: global.text_fill_exits
+                    fill: *text_fill_exits
                     size: [[16,9px],[17,10px],[20,12px]]
-                    #stroke: { color: global.highway1, width: [[12,2px],[14,3px],[15,3px]] }
+                    #stroke: { color: *highway1, width: [[12,2px],[14,3px],[15,3px]] }
         later:
             filter: { $zoom: { min: 19 } }
             draw:
@@ -4115,912 +4421,1264 @@ layers:
                     font:
                         weight: 600
 
-    pois:
-        data: { source: mapzen, layer: pois }
-        #visible: global.label_visible_poi_landuse
+    pois_and_landuse_labels:
+        data: { source: mapzen, layer: [pois,landuse] }
+        visible: *label_visible_poi_landuse
         filter:
             all:
-                - not: { kind: [building,address,farm,apron,residential,commercial,industrial] }
+                - not: { kind: [building,address,apron,residential] }
                 - $geometry: point
                 # White list a few kinds to "always" show per the tile zoom inclusion, else test feature's min_zoom
-                #- function() { return feature.min_zoom <= $zoom }
-                - function() { if( feature.kind == 'attraction' || feature.kind == 'landmark' || feature.kind == 'hunting' || feature.kind == 'dive_centre' || feature.kind == 'gas_canister' || feature.kind == 'hunting' || feature.kind == 'fishing_area' || feature.kind == 'playground' || feature.kind == 'toilets' ) { return true } else { return feature.min_zoom <= $zoom } }
+                - function() { if( feature.kind == 'attraction' || feature.kind == 'landmark' || feature.kind == 'playground' || feature.kind == 'toilets' ) { return true } else { return feature.min_zoom <= $zoom } }
+                - any:
+                    - area: false
+                      all:
+                          - $zoom: { min: 12 }
+                    - area: false
+                      elevation: true
+                      all:
+                          - $zoom: { min: 11 }
+                    - area: true
+                      all:
+                          - kind: true
         draw:
             icons:
-                visible: global.icon_visible_poi_landuse
                 size: [[13, 18px], [16, 18px], [18, 22px]]
-                sprite: function() { return feature.kind; }
-                sprite_default: generic
                 interactive: global.interactive
-                priority: 65 #function() { return (feature.min_zoom && Math.floor(feature.min_zoom * 1000)) || 65; }
+                visible: false
+                priority: 65
                 repeat_group: abc
-                buffer: 7px
                 text:
-                    visible: global.text_visible_poi_landuse
+                    visible: false    # labels are enabled by each layer below
                     text_source: global.ux_language_text_source
-                    text_wrap: 18
-                    max_lines: 3
+                    move_into_tile: false # preserves text alignment w/icons in JS
+                    buffer: 7px
                     font:
-                        family: global.text_font_family
+                        family: *text_font_family
                         weight: 600
                         fill: [0.10,0.10,0.10]
-                        size: [[13,10px],[14,10px],[18,11px]]
-                        stroke: { color: global.text_stroke, width: 3 }
+                        size: 10px
+                        stroke: { color: *text_stroke, width: 3 }
             text:
                 visible: false    # labels are enabled by each layer below, and these are only for special cases like enclosures
                 move_into_tile: false # preserves text alignment w/icons in JS
                 interactive: global.interactive
                 text_source: global.ux_language_text_source
                 font:
-                    family: global.text_font_family
+                    family: *text_font_family
                     weight: 600
                     fill: [0.10,0.10,0.10]
-                    size: [[13,10px],[14,10px],[18,11px]]
-                    stroke: { color: global.text_stroke, width: 3 }
-        # improve legibility at high zooms
+                    size: 10px
+                    stroke: { color: *text_stroke, width: 3 }
+        poi_labels-z14:
+            filter: { $zoom: [14] }
+            draw: { icons: { text: { font: { size: 10px } } } }
+        poi_labels-z15:
+            filter: { $zoom: [15,16,17] }
+            draw: { icons: { text: { font: { size: 10px, stroke: { width: 2 } } } } }
         poi_labels-z18:
-            filter: { $zoom: { min: 18 } }
-            draw:
-                icons:
-                    text:
-                        # some pois have really long names
-                        max_lines: 5
+            filter: { $zoom: [18,19] }
+            draw: { icons: { text: { font: { size: 11px, weight: 600, stroke: { width: 3 } } } } }
+        poi_labels-z20-up:
+            filter: { $zoom: { min: 20 } }
+            draw: { icons: { text: { font: { size: 11px, weight: 600, stroke: { width: 3 }  } } } }
 
+        # since the blocks below are filtering by area and by name, we need a block here
+        # that adjusts the color by kind first
         text-colours:
             greens:
-                filter:
-                    kind: [park, national_park, conservation, protected_area, nature_reserve, forest, grass, beach, battlefield]
+                filter: { kind: [park, national_park, "park or protected land", conservation, protected_area, nature_reserve, forest, grass, beach, battlefield] }
                 draw:
                     icons:
                         text:
                             font:
                                 fill: [0.032,0.522,0.530]
-                                style: italic
-                                size: [[13,11px],[14,11px],[18,12px]]
-
-        has-name:
-            filter: { name: true }
-            # match 1:1 correlations between data and sprite name
-            # draw:
-            #     icons:
-            #         visible: false
-            direct-match:
-                filter:
-                    area: false
+                                weight: 600
+                                stroke:
+                                    color: *text_stroke_park
+        no-name:
+            filter: { name: false }
+            sports-pitch:
+                filter: { kind: [grass, pitch], $geometry: point, area: true, $zoom: { min: 16 } }
                 draw:
                     icons:
-                        # sprite_source: kind
-                        sprite: function() { return feature.kind; }
-                        visible: global.icon_visible_poi_landuse
-            # add generic icon at high zoom, if direct match fails
-            generic-icons:
-                filter: { $zoom: { min: 18 }, area: false }
+                        sprite: function() { return feature.kind_detail; }
+                        visible: *icon_visible_poi_landuse_e
+                        priority: 49
+                baseball:
+                    filter: { kind_detail: baseball }
+                    draw: { icons: { sprite: baseball } }
+                basketball:
+                    filter: { kind_detail: basketball }
+                    draw: { icons: { sprite: basketball } }
+                football:
+                    filter: { kind_detail: football }
+                    draw: { icons: { sprite: football } }
+                hockey:
+                    filter: { kind_detail: hockey }
+                    draw: { icons: { sprite: hockey } }
+                soccer:
+                    filter: { kind_detail: soccer }
+                    draw: { icons: { sprite: soccer } }
+                tennis:
+                    filter: { kind_detail: tennis }
+                    draw: { icons: { sprite: tennis } }
+            tree:
+                filter: { kind: tree, $zoom: { min: 18 } }
                 draw:
                     icons:
-                        priority: 47
-                        sprite_default: generic
-                        visible: global.icon_visible_poi_landuse
-
-            # add generic icon at high zoom
-            default-label-names:
-                filter: { $zoom: { min: 13 }, area: false }
+                        # TODO: put tree icons behind the buildings
+                        # See SF State University #20/37.72314/-122.47772
+                        sprite: tree
+                        color: [0.145,0.745,0.643]
+                        visible: *icon_visible_poi_landuse_e
+                z18:
+                    filter: { $zoom: [18] }
+                    draw:
+                        icons:
+                            color: [0.459,0.765,0.722]
+                            sprite: tree-s
+                z19:
+                    filter: { $zoom: [19] }
+                    draw:
+                        icons:
+                            sprite: tree
+            gate:
+                filter: { kind: gate, $zoom: { min: 19 } }
                 draw:
                     icons:
+                        # to circle black generic
+                        sprite: gate
+                        visible: *icon_visible_poi_landuse_e
                         text:
-                            visible: global.text_visible_poi_landuse
-            peak:
-                filter: { kind: [peak, volcano] }
+                            text_source: function() { return 'gate'; }
+            toilets:
+                filter: { kind: toilets, $zoom: { min: 16 }  }
+                draw: { icons: { sprite: toilets, visible: *icon_visible_poi_landuse_e } }
+            toilets:
+                filter: { kind: toilets, $zoom: { min: 16 }  }
+                draw: { icons: { sprite: toilets, visible: *icon_visible_poi_landuse_e } }
+            playground:
+                filter: { kind: playground, $zoom: { min: 18 }  }
+                draw: { icons: { sprite: playground, visible: *icon_visible_poi_landuse_e } }
+            picnic_site:
+                filter: { kind: [picnic_site, picnic_table], $zoom: { min: 15 }  }
+                draw: { icons: { sprite: picnic_site, visible: *icon_visible_poi_landuse_e } }
+            information:
+                filter: { kind: information, $zoom: { min: 18 }  }
+                draw: { icons: { sprite: information, visible: *icon_visible_poi_landuse_e } }
+            drinking_water:
+                filter: { kind: drinking_water, $zoom: { min: 18 }  }
+                draw: { icons: { sprite: drinking_water, visible: *icon_visible_poi_landuse_e } }
+            traffic_signals:
+                filter: { kind: traffic_signals, $zoom: { min: 18 } }
+                draw:   { icons: { sprite: traffic_signals, visible: *icon_visible_poi_landuse_e } }
+            bicycle_parking:
+                filter: { kind: [bicycle_parking], $zoom: { min: 19 } }
+                draw:   { icons: { sprite: bicycle_parking, visible: *icon_visible_poi_landuse_e } }
+            parking:
+                filter: { kind: parking, $zoom: { min: 17 } }
+                draw:
+                    icons:
+                        sprite: parking
+                        visible: *icon_visible_poi_landuse_e
+            power_tower:
+                filter: { kind: [power_tower], $zoom: { max: 16 } }
+                draw:   { icons: { visible: false } }
+            power_pole:
+                filter: { kind: [power_pole], $zoom: { max: 17 } }
+                draw:   { icons: { visible: false } }
+            playgrounds:
+                filter:
+                    all:
+                        - kind: [playground, allotments, attraction, landmark]
+                    any:
+                        - { $zoom: [15], area: { min: 600 } }
+                        - { $zoom: [16], area: { min: 300 } }
+                        - { $zoom: { min: 17 } }
+                draw:
+                    icons:
+                        sprite: function() { return feature.kind; }
+            pylon:
+                filter: { kind: [pylon], $zoom: { max: 17 } }
+                draw:   { icons: { visible: false }}
+            bbq:
+                filter: { kind: [bbq], $zoom: { min: 17 } }
+                draw:
+                    icons:
+                        sprite: bbq
+                        visible: *icon_visible_poi_landuse_e
+            ranger_station:
+                filter: { kind: [ranger_station], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: ranger_station, visible: *icon_visible_poi_landuse_e } }
+            trailhead:
+                filter: { kind: [trailhead], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: trailhead, visible: *icon_visible_poi_landuse_e } }
+            firepit:
+                filter: { kind: [firepit], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: firepit, visible: *icon_visible_poi_landuse_e } }
+            swimming_area:
+                filter: { kind: [swimming_area], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: swimming_area, visible: *icon_visible_poi_landuse_e } }
+            fishing_area:
+                filter: { kind: [fishing_area], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: fishing_area, visible: *icon_visible_poi_landuse_e } }
+            slipway:
+                filter: { kind: [slipway], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: slipway, visible: *icon_visible_poi_landuse_e } }
+            hot_spring:
+                filter: { kind: [hot_spring], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: hot_spring, visible: *icon_visible_poi_landuse_e } }
+            spring:
+                filter: { kind: [spring], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: spring, visible: *icon_visible_poi_landuse_e } }
+            shower:
+                filter: { kind: [shower], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: shower, visible: *icon_visible_poi_landuse_e } }
+            geyser:
+                filter: { kind: [geyser], $zoom: { min: 15 } }
+                draw:   { icons: { sprite: geyser, visible: *icon_visible_poi_landuse_e } }
+            observatory:
+                    filter: { kind: [observatory], $zoom: { min: 14 } }
+                    draw:   { icons: { sprite: observatory, visible: *icon_visible_poi_landuse_e } }
+            water_tower:
+                    filter: { kind: [water_tower], $zoom: { min: 15 } }
+                    draw:   { icons: { sprite: water_tower, visible: *icon_visible_poi_landuse_e } }
+            battlefield:
+                    filter: { kind: [battlefield] }
+                    draw:   { icons: { sprite: battlefield, visible: *icon_visible_poi_landuse_e } }
+            walking-or-bicycle_junction:
+                filter: { kind: [bicycle_junction, walking_junction] }
+                draw:
+                    icons:
+                        sprite: generic
+                        visible: *icon_visible_poi_landuse_e
+                        text:
+                            visible: true
+                            text_source: ref
+            outdoor-needing-icons:
+                filter: { kind: [boat_rental, bicycle_repair_station, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, communications_tower, silo, putin, egress, hazard, put_in_egress, rapid, beacon, cross, water_well, saddle, dune, sinkhole, rock, stone, bicycle_junction, walking_junction, dam, boat_storage, windmill, horse, fire_lookout, fee_station, rest_area] }
                 draw:
                     icons:
-                        visible: global.icon_visible_poi_landuse
                         priority: 43
-                        text:  { visible: global.text_visible_poi_landuse }
-                low-priority-early-z11:
-                    filter: { kind_tile_rank: { min: 3 }, $zoom: [11,12] }
-                    draw:
-                        icons:
-                            visible: false
-                            text: { visible: false }
-                low-priority-early-z13:
-                    filter: { kind_tile_rank: { min: 4 }, $zoom: [13] }
-                    draw:
-                        icons:
-                            visible: false
-                            text: { visible: false }
-                peak-labels-later:
-                    filter: { kind: [peak, volcano], $zoom: { min: 14 } }
+                        sprite: generic
+                hide-early:
+                    filter: { kind: [recreation_track, dam] }
                     draw:
                         icons:
-                            text:
-                                text_source: function() { if( feature.name && feature.elevation ) { return feature.name + "\n" + feature.elevation + "m"; } else { if( feature.name ) { return feature.name; } else { return feature.elevation; } } }
-            waterfall-early:
-                filter: { kind: [waterfall], $zoom: { max: 14 } }
+                            priority: 50
+                    early:
+                        filter: { $zoom: { max: 15 } }
+                        draw:
+                            icons:
+                                visible: false
+        has-name:
+            filter: { name: true }
+            # match 1:1 correlations between data and sprite name
+            direct-match:
+                filter:
+                    all:
+                        - area: false
                 draw:
                     icons:
-                        visible: global.icon_visible_poi_landuse
-                        text:  { visible: global.text_visible_poi_landuse }
-                low-priority-early-z11:
-                    filter: { kind_tile_rank: { min: 3 }, $zoom: [11,12] }
+                        # sprite_source: kind
+                        sprite: function() { return feature.kind; }
+                        visible: *icon_visible_poi_landuse
+            # add generic icon at high zoom, if direct match fails
+            generic-icons:
+               filter: { $zoom: { min: 18 }, area: false }
+               draw:
+                   icons:
+                       priority: 47
+                       sprite_default: generic
+                       visible: *icon_visible_poi_landuse
+
+            # add generic icon at high zoom
+            default-label-names:
+               filter: { $zoom: { min: 13 }, area: false }
+               draw:
+                    icons:
+                        text:
+                           visible: *text_visible_poi_landuse
+            landuse-labels-green-areas-national-park:
+                filter:
+                    all:
+                        - area: true
+                        - $geometry: point
+                        - kind: [national_park]
+                    any:
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [4],  area: { min: 3000000000 } }
+                        - { $zoom: [5],  area: { min: 3000000000 } }
+                        - { $zoom: [6],  area: { min: 500000000 } }
+                        - { $zoom: [7,8,9],  area: { min: 100000000 } }
+                        - { $zoom: [10], area: { min: 50000000 } }
+                        - { $zoom: [11], area: { min: 25000000 } }
+                        - { $zoom: [12], area: { min: 5000000 } }
+                        - { $zoom: [13], area: { min: 200000 } }
+                        - { $zoom: [14], area: { min: 50000 } }
+                        - { $zoom: { min: 15 } }
+                national-park:
+                    # yosemite national park, joshua tree national park
+                    filter: function() { return feature.name && ((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
+                    visible: *label_visible_landuse_green
                     draw:
                         icons:
-                            visible: false
-                            text: { visible: false }
-                low-priority-early-z13:
-                    filter: { kind_tile_rank: { min: 4 }, $zoom: [13] }
+                            visible: *icon_visible_landuse_green
+                            sprite: park
+                            priority: 41
+                            text:
+                                visible: *text_visible_landuse_green
+                                text_source: global.ux_language_text_source
+                                font:
+                                    style: italic
+                                    stroke: { color: *text_stroke_park, width: 4 }
+                    natl-park-labels-z4-z5:
+                        filter: { $zoom: [4,5] }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { font: { size: 9px, stroke: { width: 2px } } }
+                    natl-park-labels-z6:
+                        filter: { $zoom: [6] }
+                        draw:
+                            icons:
+                                text: { font: { size: 9px, stroke: { width: 2px } } }
+                    natl-park-labels-z7:
+                        filter: { $zoom: [7] }
+                        draw:
+                            icons:
+                                text: { font: { size: 10px, stroke: { width: 2px } } }
+                    natl-park-labels-z8:
+                        filter: { $zoom: [8,9] }
+                        draw:
+                            icons:
+                                text: { font: { size: 11px, stroke: { width: 2px } } }
+                    natl-park-labels-z10:
+                        filter: { $zoom: {min: 10, max: 14 } }
+                        draw:
+                            icons:
+                                text: { font: { size: 12px } }
+                    poi_labels-z14:
+                        filter: { $zoom: [14] }
+                        draw: { icons: { text: { font: { size: 11px } } } }
+                    poi_labels-z15:
+                        filter: { $zoom: [15,16,17] }
+                        draw: { icons: { text: { font: { size: 11px } } } }
+                    poi_labels-z18:
+                        filter: { $zoom: [18,19] }
+                        draw: { icons: { text: { font: { size: 11px } } } }
+                    poi_labels-z20-up:
+                        filter: { $zoom: { min: 20 } }
+                        draw: { icons: { text: { font: { size: 11px } } } }
+            landuse-labels-green-areas-not-national-park:
+                filter:
+                    all:
+                        - area: true
+                        - $geometry: point
+                        - kind: [park, national_park, "park or protected land", conservation, protected_area, nature_reserve, forest, grass]
+                    any:
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [5],    area: { min: 10000000000 } }
+                        - { $zoom: [6,7],  area: { min: 5000000000 } }
+                        - { $zoom: [8],    area: { min: 1000000000 } }
+                        - { $zoom: [9],    area: { min: 100000000 } }
+                        - { $zoom: [10],   area: { min: 50000000 } }
+                        - { $zoom: [11],   area: { min: 10000000 } }
+                        - { $zoom: [12],   area: { min: 5000000 } }
+                        - { $zoom: [13],   area: { min: 200000 } }
+                        - { $zoom: [14],   area: { min: 50000 } }
+                        - { $zoom: [15],   area: { min: 10000 } }
+                        - { $zoom: [16],   area: { min: 1000 } }
+                        - { $zoom: { min: 17 } }
+                not-national-park:
+                    filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
                     draw:
                         icons:
-                            visible: false
-                            text: { visible: false }
-            waterfall-labels:
-                filter: { kind: [waterfall], $zoom: { min: 14 } }
-                draw:
-                    icons:
-                        text:
-                            text_source: function() { if( feature.name && feature.height ) { return feature.name + "\n" + feature.height + "m"; } else { if( feature.name ) { return feature.name; } else { return feature.height; } } }
-            playgrounds_allotments_attraction_landmark_supermarket:
+                            visible: *icon_visible_landuse_green
+                            sprite: park
+                            priority: 41
+                            text:
+                                visible: *text_visible_landuse_green
+                                font:
+                                    #fill: [0.032,0.522,0.530]
+                                    # fill: [0.093,0.473,0.408]
+                                    size: 11px
+                                    style: italic
+                                    stroke: { color: *text_stroke_park, width: 3 }
+                    green-areas-z6:
+                        # mojave national preserve
+                        filter: { $zoom: [6] }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { font: { size: 10px, stroke: { width: 2px } } }
+                    green-areas-z7:
+                        filter: { $zoom: [7] }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { font: { size: 10px, stroke: { width: 2px } } }
+                    green-areas-z17-up:
+                        filter: { $zoom: { min: 17 } }
+                        draw:
+                            icons:
+                                text:
+                                    font:
+                                        size: 11px
+                                        stroke: { color: *text_stroke, width: 4 }
+
+                    wilderness-areas:
+                        filter: function() { return feature.name && (feature.name.indexOf("Wilderness") > -1 || feature.name.indexOf("BLM") > -1) }
+                        draw:
+                            icons:
+                                sprite: forest
+                        early:
+                           filter: { $zoom: { max: 8 } }
+                           draw:
+                                icons:
+                                    visible: false
+                                    text: { visible: false }
+                    early-not-national-park:
+                        filter: { not: { kind: [national_park] }, $zoom: { max: 6 } }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { visible: false }
+                    not-national-park:
+                        filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
+                        # draw:
+                        #     icons:
+                        #         sprite: park
+                        early:
+                            filter: { $zoom: { max: 8 } }
+                            draw:
+                                icons:
+                                    visible: false
+                                    text: { visible: false }
+                    forest:
+                        filter: function() { return ( (feature.name && feature.name.indexOf("Forest") > -1) || (feature.protect_class >=6 && feature.name.indexOf("Park") < 0) ) }
+                        draw:
+                            icons:
+                                sprite: forest
+                        early:
+                            filter: { $zoom: { max: 8 } }
+                            draw:
+                                icons:
+                                    visible: false
+                                    text: { visible: false }
+                    hide-till-later:
+                        filter: { kind: [grass], $zoom: { max: 16 } }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { visible: false }
+                    only-text-later:
+                        filter: { kind: [grass], $zoom: { min: 16 } }
+                        draw:
+                            icons:
+                                visible: false
+                                text: { font: { style: italic } }
+            battlefield:
                 filter:
                     all:
-                        - kind: [playground, allotments, attraction, landmark, supermarket]
                         - area: true
                         - $geometry: point
+                        - kind: [battlefield]
                     any:
-                        - { $zoom: [15], area: { min: 600 } }
-                        - { $zoom: [16], area: { min: 300 } }
-                        - { $zoom: { min: 17 }, area: true }
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [4],  area: { min: 3000000000 } }
+                        - { $zoom: [5],  area: { min: 3000000000 } }
+                        - { $zoom: [6],  area: { min: 500000000 } }
+                        - { $zoom: [7,8,9],  area: { min: 10000000 } }
+                        - { $zoom: [10], area: { min: 5000000 } }
+                        - { $zoom: [11], area: { min: 5000000 } }
+                        - { $zoom: [12], area: { min: 5000000 } }
+                        - { $zoom: [13], area: { min: 200000 } }
+                        - { $zoom: [14], area: { min: 50000 } }
+                        - { $zoom: { min: 15 } }
                 draw:
                     icons:
-                        visible: global.icon_visible_poi_landuse
+                        visible: *icon_visible_landuse_green
+                        sprite: battlefield
                         priority: 41
                         text:
-                            visible: global.text_visible_poi_landuse
-                            # font:
-                            #     size: 10px
-                            #     stroke: { color: global.text_stroke, width: 4 }
-            tourism-related:
+                            visible: *text_visible_landuse_green
+                            font:
+                                #fill: [0.058,0.605,0.615]
+                                # fill: [0.093,0.473,0.408]
+                                style: italic
+                                stroke: { color: *text_stroke_park, width: 4 }
+            beach:
                 filter:
                     all:
-                        - kind: [zoo, theme_park, resort, aquarium, winery, maze, stadium, enclosure, animal]
                         - area: true
                         - $geometry: point
+                        - kind: [beach]
                     any:
                         # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: { min: 11 }, area: { min: 400000 } }
-                        - { $zoom: { min: 12 }, area: { min: 200000 } }
-                        - { $zoom: { min: 13 }, area: { min: 50000 } }
-                        - { $zoom: { min: 14 }, area: { min: 20000 } }
-                        - { $zoom: { min: 15 }, area: { min: 2000 } }
-                        - { $zoom: { min: 16 } }
+                        - { $zoom: [10],   area: { min: 300000 } }
+                        - { $zoom: [11],   area: { min: 100000 } }
+                        - { $zoom: [12],   area: { min: 50000 } }
+                        - { $zoom: [13],   area: { min: 50000 } }
+                        - { $zoom: [14],   area: { min: 20000 } }
+                        - { $zoom: [15],   area: { min: 10000 } }
+                        - { $zoom: [16],   area: { min: 1000 } }
+                        - { $zoom: { min: 17 } }
                 draw:
                     icons:
-                        sprite: function() { return feature.kind; }
-                        sprite_default: generic
-                        visible: global.icon_visible_poi_landuse
-                        priority: 43
+                        visible: *icon_visible_landuse_green
+                        sprite: beach
                         text:
-                            visible: global.text_visible_poi_landuse
-                            # font:
-                            #     size: 10px
-                            #     stroke: { color: global.text_stroke, width: 4 }
-            outdoor-needing-icons:
-                filter: { kind: [bicycle_repair_station, cycle_barrier, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, communications_tower, putin, egress, hazard, put_in_egress, rapid, beacon, cross, mineshaft, adit, water_well, saddle, dune, sinkhole, rock, stone, bicycle_junction, walking_junction, dam, boat_storage, windmill, fishing, recreation_track, horse, fire_lookout, fee_station, rest_area] }
-                draw:
-                    icons:
-                        order: 41
-                        sprite: generic
-            outdoor-has-icons:
-                filter: { kind: [outdoor, lighthouse, saddle, picnic_area, picnic_table, camp_site, ski, mine, zoo, museum, gas, gas_canister, slipway, mineshaft, adit, recreation_track, playground, allotments, attraction, landmark] }
-                draw:
-                    icons:
-                        order: 41
-            not-outdoor-not-landuse:
-                filter: { area: false, not: { kind: [park, national_park, outdoor, bicycle_repair_station, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, bicycle_junction, walking_junction, dam, boat_storage, windmill, playground, allotments, attraction, landmark] } }
-                draw:
-                    icons:
-                        order: 45
-
-        # source icon sprite from something other than kind
-        sports-pitch:
-            filter: { kind: [grass, pitch] }
-            draw:
-                icons:
-                    sprite: function() { return feature.kind_detail; }
-                    # needs a better recreation icon, so just use generic (default) for now
-                    #sprite_default: sports
-                    #visible: global.icon_visible_poi_landuse_e
-                    priority: 69
-        place_of_worship:
-            filter:
-                kind: [place_of_worship, wayside_chapel]
-            draw:
-                icons:
-                    sprite: function() { return feature.religion; }
-                    sprite_default: place_of_worship
-        # TODO: some or all of this may be unnecessary for the sprite, but is necessary for the early filter
-        building-icon:
-            filter:
-                kind: [apartments, auditorium, building, hangar, manor, recreation_center, retirement_home, terminal]
-            draw:
-                icons:
-                    sprite: building
-            early:
+                            visible: *text_visible_landuse_green
+            airport:
                 filter:
+                    all:
+                        - kind: [airport, aerodrome]
+                        - area: true
+                        - $geometry: point
                     any:
                         # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: [14], area: { max: 200000 } }
-                        - { $zoom: [15], area: { max: 20000 } }
-                        - { $zoom: [16], area: { max: 5000 } }
-                        - { $zoom: [17], area: { max: 1000 } }
+                        - { $zoom: [9],  area: { min: 10000000 } }
+                        - { $zoom: [10], area: { min: 10000000 } }
+                        - { $zoom: [11], area: { min: 5000000 } }
+                        - { $zoom: [12], area: { min: 5000000 } }
+                        - { $zoom: [13], area: { min: 500000 } }
+                        - { $zoom: [14], area: { min: 20000 } }
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [15], area: { min: 10000 } }
+                        - { $zoom: [16], area: { min: 5000 } }
+                        - { $zoom: [17], area: { min: 2000 } }
+                        - { $zoom: { min: 18 } }
                 draw:
                     icons:
-                        visible: false
-        #end different icon sprites
-
-        #most POI icons without name should be hidden, except these
-        no-name:
-            filter: { name: false }
-            draw:
-                icons:
-                    visible: false
-            # eg park polygons in SF that have area but no name, sigh
-            no-name-no-area:
+                        sprite: airport
+                        visible: *icon_visible_landuse_green
+                        priority: 42
+                        text:
+                            visible: *text_visible_landuse_green
+                            text_source: global.ux_language_text_source_iata
+                            font:
+                                #fill: [0.10,0.10,0.10]
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+                early:
+                    filter: { $zoom: [9,10,11] }
+                    # todo: huh?
+                    draw: { icons: { text: { text_source: iata, font: { size: 11px } } } }
+                early2:
+                    filter: { $zoom: { min: 12, max: 14 } }
+                    draw: { icons: { text: { font: { size: 11px } } } }
+            university:
                 filter:
-                    kind: true
-                    name: false
+                    all:
+                        - kind: [university, college]
+                        - area: true
+                        - $geometry: point
+                        - not: { $layer: buildings }
+                    any:
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [9],   area: { min: 10000000 } }
+                        - { $zoom: [10], area: { min: 5000000 } }
+                        - { $zoom: [11], area: { min: 2000000 } }
+                        - { $zoom: [12], area: { min: 500000 } }
+                        - { $zoom: [13], area: { min: 100000 } }
+                        - { $zoom: [14], area: { min: 100000 } }
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [15], area: { min: 40000 } }
+                        - { $zoom: [16], area: { min: 5000 } }
+                        - { $zoom: [17], area: { min: 2000 } }
+                        - { $zoom: { min: 18 } }
+                visible: *label_visible_landuse_green
                 draw:
                     icons:
-                        visible: false
-            # we agree with server value, always show
-            always-show:
-                filter:
-                    kind: [bbq,bicycle_junction,firepit,fishing_area,geyser,hot_spring,observatory,picnic_site,picnic_table,playground,power_pole,power_tower,pylon,shower,slipway,swimming_area,toilets,trailhead,walking_junction,water_tower]
-                draw:   { icons: { visible: global.icon_visible_poi_landuse_e } }
-
-            # probaly difference with server, selectively show by zoom
-            z15-always-show-but-server-show-later-z15-server-14:
-                filter: { kind: [ranger_station, spring], $zoom: { min: 15 } }             # server says min_zoom: 14
-                draw:   { icons: { visible: global.icon_visible_poi_landuse_e } }
-            z17:
-                filter:
-                    $zoom: { min: 17 }
-                    kind: [parking]
-                draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
-            z18:
-                # for different styles, different sets
-                # since [picnic_site] doesn't have bubble-wrap icon, it's omitted here
-                filter:
-                    $zoom: { min: 18 }                                     # same as BW, server at 17 now (information is 16)
-                    kind: [drinking_water, information, playground, toilets, traffic_signals, picnic_site]
-                draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
-            z19:
-                filter:
-                    $zoom: { min: 19 }                                     # same as BW, server at 17 now
-                    kind: [bicycle_parking, gate]
-                draw: { icons: { visible: global.icon_visible_poi_landuse_e } }
-
-
-            # area based show / hide
-            playgrounds:
+                        sprite: college
+                        visible: *icon_visible_landuse_green
+                        priority: 41
+                        text:
+                            visible: *text_visible_landuse_green
+                            font:
+                                #fill: [0.10,0.10,0.10]
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+                # early:
+                #     filter: { $zoom: { max: 12 } }
+                #     draw: { icons: { text: { visible: false } } }
+                early2:
+                    filter: { $zoom: { max: 14 } }
+                    draw: { icons: { text: { font: { size: 10px } } } }
+            school:
                 filter:
                     all:
-                        - kind: [playground, allotments, attraction, landmark]
+                        - kind: [school, kindergarten]
+                        - area: true
+                        - $geometry: point
+                        - not: { $layer: buildings }
                     any:
-                        - { $zoom: [15], area: { min: 600 } }
-                        - { $zoom: [16], area: { min: 300 } }
-                        - { $zoom: { min: 17, area: true } }
+                        # show labels for smaller landuse areas at higher zooms
+                        #- { $zoom: [13], area: { min: 100000 } }
+                        #- { $zoom: [14], area: { min: 50000 } }
+                        # show labels for smaller landuse areas at higher zooms
+                        #- { $zoom: [15], area: { min: 10000 } }
+                        - { $zoom: [16], area: { min: 5000 } }
+                        - { $zoom: [17], area: { min: 2000 } }
+                        - { $zoom: { min: 18 } }
                 draw:
                     icons:
-                        visible: global.icon_visible_poi_landuse_e
-
-            # special icon and text stuff
-            sports-pitch:
+                        sprite: school
+                        visible: *icon_visible_landuse_green
+                        priority: 41
+                        text:
+                            visible: *text_visible_landuse_green
+                            font:
+                                #fill: [0.10,0.10,0.10]
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+                early:
+                    filter: { $zoom: { max: 14 } }
+                    draw: { icons: { text: { font: { size: 11px } } } }
+            winter_sports:
                 filter:
-                    $zoom: { min: 17 }
-                    kind: [grass, pitch]
-                    kind_detail: [baseball, basketball, football, hockey, soccer, tennis]
-                draw:
-                    icons:
-                        visible: global.icon_visible_poi_landuse_e
-                        priority: 69
-            tree:
-                filter: { kind: tree, $zoom: { min: 18 } }
-                draw:
-                    icons:
-                        # TODO: put tree icons behind the buildings
-                        # See SF State University #20/37.72314/-122.47772
-                        color: [0.145,0.745,0.643]
-                        visible: global.icon_visible_poi_landuse_e
-                z18:
-                    filter: { $zoom: [18] }
-                    draw:
-                        icons:
-                            color: [0.459,0.765,0.722]
-                            sprite: tree-s
-            gate:
-                filter: { kind: gate, $zoom: { min: 19 } }
+                    all:
+                        - kind: winter_sports
+                        - area: true
+                        - $geometry: point
+                    any:
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [10], area: { min: 5000000 } }
+                        - { $zoom: [11], area: { min: 2000000 } }
+                        - { $zoom: [12], area: { min: 500000 } }
+                        - { $zoom: [13], area: { min: 100000 } }
+                        - { $zoom: [14], area: { min: 100000 } }
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [15], area: { min: 40000 } }
+                        - { $zoom: [16], area: { min: 5000 } }
+                        - { $zoom: [17], area: { min: 2000 } }
+                        - { $zoom: { min: 18 } }
                 draw:
                     icons:
+                        sprite: ski
+                        visible: *icon_visible_landuse_green
+                        priority: 41
                         text:
-                            text_source: function() { return 'gate'; }
-            walking-or-bicycle_junction:
-                filter: { kind: [bicycle_junction, walking_junction] }
+                            visible: *text_visible_landuse_green
+                            font:
+                                #fill: [0.10,0.10,0.10]
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+#                early:
+#                    filter: { $zoom: { max: 14 } }
+#                    draw: { icons: { text: { font: { size: 10px } } } }
+            tourism-related:
+                filter:
+                    all:
+                        - kind: [zoo, theme_park, resort, aquarium, winery, maze, stadium, enclosure, animal]
+                        - area: true
+                        - $geometry: point
+                    any:
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: { min: 11 }, area: { min: 400000 } }
+                        - { $zoom: { min: 12 }, area: { min: 200000 } }
+                        - { $zoom: { min: 13 }, area: { min: 50000 } }
+                        - { $zoom: { min: 14 }, area: { min: 20000 } }
+                        - { $zoom: { min: 15 }, area: { min: 2000 } }
+                        - { $zoom: { min: 16 } }
                 draw:
                     icons:
+                        sprite: function() { return feature.kind; }
+                        sprite_default: generic
+                        visible: *icon_visible_poi_landuse
+                        priority: 43
+                        text:
+                            visible: *text_visible_poi_landuse
+                            font:
+                                #fill: [0.10,0.10,0.10]
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+                enclosure:
+                    filter: { kind: [enclosure, animal] }
+                    draw:
+                        icons:
+                            visible: false
+                            sprite_default: enclosure
                         text:
-                            text_source: ref
-
-            z-hide-z15:
+                            text_wrap: 10
+                            font:
+                                style: italic
+                                weight: 400
+                #early-sizing:
+#                    filter: { $zoom: { max: 14 } }
+#                    draw: { icons: { text: { font: { size: 10px } } } }
+            playgrounds_allotments_attraction_landmark_supermarket:
                 filter:
-                    $zoom: { max: 15 }
-                    kind: [rest_area]
-                draw: { icons: { visible: false } }
-
-            outdoor-special-priority:
-                filter: { kind: [beacon,bicycle_junction,bicycle_repair_station,boat_storage,communications_tower,cross,dam,dune,egress,fee_station,fire_lookout,hazard,horse,life_ring,lifeguard_tower,petroleum_well,power_pole,power_tower,put_in_egress,putin,rapid,rest_area,rock,saddle,silo,sinkhole,stone,walking_junction,waste_disposal,water_point,water_well,watering_place,windmill] }
+                    all:
+                        - kind: [playground, allotments, attraction, landmark, supermarket]
+                        - area: true
+                        - $geometry: point
+                    any:
+                        - { $zoom: [15], area: { min: 600 } }
+                        - { $zoom: [16], area: { min: 300 } }
+                        - { $zoom: { min: 17 } }
                 draw:
                     icons:
-                        priority: 43
-                        visible: global.icon_visible_poi_landuse_e
-                hide-early:
-                    filter: { kind: [dam,recreation_track] }
+                        visible: *icon_visible_landuse_green
+                        priority: 41
+                        text:
+                            visible: *text_visible_landuse_green
+                            font:
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+                attraction:
+                    filter: { kind: [attraction] }
                     draw:
                         icons:
-                            priority: 50
-                    early:
-                        filter: { $zoom: { max: 15 } }
-                        draw:
-                            icons:
-                                visible: false
-
-
-        # NOTE: all natural_* should only be in landuse layer
-        suppress-icon-always:
-            filter:
-                kind: [natural_forest, natural_park, natural_wood]
-            draw:
-                icons:
-                    size: 0px
-                    priority: 100
-                    text:
-                        font:
-                            fill: '#666'
-                            family: global.text_font_family
-                            style: italic
-                            size: 11px
-            # This should work, but doesn't. hmmm
-            no-area:
+                            sprite: attraction
+                landmark:
+                    filter: { kind: [landmark] }
+                    draw:
+                        icons:
+                            sprite: landmark
+            glacier:
                 filter:
-                    area: false
-                    $zoom: { max: 16 }
+                    all:
+                        - kind: glacier
+                        - area: true
+                        - $geometry: point
+                    any:
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [10],    area: { min: 20000000 } }
+                        - { $zoom: [11],    area: { min: 5000000 } }
+                        - { $zoom: [12],    area: { min: 2000000 } }
+                        - { $zoom: [13],    area: { min: 500000 } }
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: { min: 14 } }
                 draw:
                     icons:
                         visible: false
-
-        # server problem: this should probably only have landuse layer label placements (not appear in pois layer)
-        suppress-icon-z17:
-            filter:
-                $zoom: { min: 17 }
-                kind: [common, grass, houseboat, pedestrian, railway, ship, wetland]
-            draw:
-                icons:
-                    size: 0px
-                    #visible: false
-                    text: { font: { style: italic } }
-
-        # the server should be setting better values here
-        z-server-friend:
-            hide-until-z12-any:
+                    text:
+                        visible: true
+                        priority: 44
+                        text_wrap: 10
+                        font:
+                            weight: 400
+                            style: italic
+                            fill: '#4ba3c5'
+            landuse-labels-not-any-above:
                 filter:
-                    kind: [landmark, museum, prison]
-                    $zoom: { max: 12 }
+                    all:
+                        - $zoom: { min: 6 }
+                        - area: true
+                        - $geometry: point
+                        - not: { kind: [park, national_park, "park or protected land", battlefield, conservation, protected_area, nature_reserve, forest, grass, beach, airport, aerodrome, university, college, school, kindergarten, winter_sports, zoo, theme_park, resort, aquarium, winery, maze, stadium, playground, allotments, attraction, landmark, glacier] }
+                    any:
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [5,6,7], area: { min: 5000000000 } }
+                        - { $zoom: [8],     area: { min: 1600000000 } }
+                        - { $zoom: [9],     area: { min: 400000000 } }
+                        - { $zoom: [10],    area: { min: 100000000 } }
+                        - { $zoom: [11],    area: { min: 25000000 } }
+                        - { $zoom: [12],    area: { min: 5000000 } }
+                        - { $zoom: [13],    area: { min: 1000000 } }
+                        - { $zoom: [14],    area: { min: 50000 } }
+                        # show labels for smaller landuse areas at higher zooms
+                        - { $zoom: [15],    area: { min: 5000 } }
+                        - { $zoom: [16],    area: { min: 2000 } }
+                        - { $zoom: { min: 17 } }
                 draw:
                     icons:
-                        visible: false
-            hide-until-z14-any:
-                filter:
-                    kind: [natural_forest, natural_park, natural_wood]
-                    $zoom: { max: 14 }
+                        sprite: function() { return feature.kind; }
+                        sprite_default: generic
+                        visible: *icon_visible_poi_landuse
+                        priority: 43
+                        text:
+                            visible: *text_visible_poi_landuse
+                            font:
+                                weight: 600
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 3 }
+                landuse-z18:
+                    filter: { $zoom: { min: 18 } }
+                    draw:
+                        icons:
+                            text:
+                                font:
+                                    size: 11px
+                                    stroke: { color: *text_stroke, width: 4 }
+                # building-like:
+                #     filter: { kind: [commercial,residential,warehouse,public,dormitory], osm_relation: false }
+                #     draw:
+                #         icons:
+                #             sprite: building
+                residential-relations-paris-wtf-early:
+                    filter: { kind: [residential], osm_relation: true, $zoom: { max: 13 } }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { visible: false }
+                residential-relations-paris-wtf:
+                    filter: { kind: [residential], osm_relation: true, $zoom: { min: 13 } }
+                    draw:
+                        icons:
+                            visible: false
+                            text:
+                                visible: true
+                                text_source: short_name
+                hide-till-later:
+                    filter: { kind: [pedestrian,common,railway,ship,houseboat,common,grass,wetland,pitch], $zoom: { max: 17 } }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { visible: false }
+                only-text-later:
+                    filter: { kind: [pedestrian,common,railway,ship,houseboat,common,grass,wetland,pitch], $zoom: { min: 17 } }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { font: { style: italic } }
+                # burial_vault-early:
+                #     filter: { kind: [burial_vault], $zoom: { max: 19 } }
+                #     draw:
+                #         icons:
+                #             visible: false
+                #             text:  { visible: false }
+                garden-area-early:
+                   filter:
+                       all:
+                           - kind: [garden, allotments]
+                       any:
+                           # limit show smaller landuse areas to higher zooms
+                           - { $zoom: [12], area: { max: 500000 } }
+                           - { $zoom: [13], area: { max: 100000 } }
+                           - { $zoom: [14], area: { max: 10000 } }
+                           - { $zoom: [15], area: { max: 5000 } }
+                   draw:
+                       icons:
+                           visible: false
+            university-poi:
+                filter: { kind: [university, college], area: false, $zoom: { max: 16 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z15-any:
+                        text:  { visible: false }
+            office-early:
                 filter:
-                    kind: [motorway_junction]
-                    $zoom: { max: 15 }
+                    any:
+                        - { kind: [insurance, office, company], $zoom: [15], area: { max: 10000 } }
+                        - { kind: [insurance, office, company], $zoom: [16], area: { max: 5000 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z15-no-area:
-                filter:
-                    area: false
-                    $zoom: { max: 15 }
-                    kind: [park]
+                        text:  { visible: false }
+            bank-early:
+                filter: { kind: [bank], $zoom: { max: 17 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z15-with-area:
-                filter:
-                    area: true
-                    $zoom: { max: 15 }
-                    kind: [nursing_home]
+                        text:  { visible: false }
+            garden-no-area-early2:
+                filter: { kind: [garden, allotments], $zoom: { max: 16 }, area: false }
                 draw:
                     icons:
                         visible: false
-            hide-until-z16-any:
-                filter:
-                    kind: [fire_station, grass, tram_stop, post_office]
-                    $zoom: { max: 16 }
+            garden-no-area-early:
+                filter: { kind: [garden, allotments], $zoom: [16], area: false }
                 draw:
                     icons:
-                        visible: false
-            hide-until-z16-no-area:
-                filter:
-                    area: false
-                    kind: [allotments, college, garden, university]
-                    $zoom: { max: 16 }
+                        priority: 45
+                        size: 14px
+                        text:  { font: { size: 10px, style: italic } }
+            garden-no-area-later:
+                filter: { kind: [garden, allotments], $zoom: { min: 17 }, area: false }
                 draw:
                     icons:
-                        visible: false
-            # no POIs for commercial, residential
-            hide-until-z17-any:
-                filter:
-                    $zoom: { max: 17 }
-                    kind: [bank, bus_stop, car_sharing, wood, platform, cafe, restaurant, fast_food, bar, place_of_worship, police]
+                        priority: 45
+                        size: 16px
+                        text:  { font: { size: 11px, style: italic } }
+            post-office-early:
+                filter: { kind: [post_office], $zoom: { max: 14 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z17-with-area:
-                filter:
-                    area: true
-                    $zoom: { max: 17 }
-                    kind: [common, grass, houseboat, pedestrian, pitch, railway, ship, wetland]
+                        text:  { visible: false }
+            pylon-early:
+                filter: { kind: [pylon], name: true, $zoom: { max: 18 } }
+                draw:   { icons: { text: { visible: false } } }
+            school-early:
+                filter: { kind: [school, kindergarten], $zoom: { max: 16 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z17-no-area:
-                filter:
-                    area: false
-                    $zoom: { max: 17 }
-                    # note: atm and drinking_water appear hear and in area versions
-                    kind: [accountant, administrative, advertising_agency, animal, architect, association, atm, bakery, bed_and_breakfast, bicycle, bicycle_parking, bicycle_rental_station, books, butcher, car, car_repair, chalet, clothes, company, computer, consulting, convenience, doityourself, drinking_water, dry_cleaning, educational_institution, emergency_phone, employment_agency, estate_agent, fashion, financial, florist, foundation, gift, government, greengrocer, guest_house, hairdresser, hostel, hotel, insurance, it, jewelry, lawyer, mast, memorial, mobile_phone, motel, newspaper, ngo, notary, optician, parking, pet, physician, political_party, post_box, religion, research, subway_entrance, tax_advisor, telecommunication, telephone, theatre, therapist, toilets, traffic_signals, travel_agent, water_tower]
+                        text:  { visible: false }
+            atm-early:
+                filter: { kind: [atm], $zoom: { max: 18 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z18-any:
-                filter:
-                    kind: [atm, bus_stop, drinking_water]
-                    $zoom: { max: 18 }
+                        text:  { visible: false }
+            bicycle-parking-early:
+                filter: { kind: [bicycle_parking], $zoom: { max: 19 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z18-no-area:
-                filter:
-                    $zoom: { max: 18 }
-                    area: false
-                    kind: [bench, parking, waste_basket]
+                        text:  { visible: false }
+            true-early:
+                filter: { kind: [true], $zoom: { max: 18 } }
                 draw:
                     icons:
                         visible: false
-            hide-until-z19-any:
-                filter:
-                    $zoom: { max: 19 }
-                    kind: [bicycle_parking, burial_vault, car_sharing]
+                        text:  { visible: false }
+            peak-early:
+                filter: { kind: [peak, volcano] }
                 draw:
                     icons:
-                        visible: false
-
-            # hide based on kind and area filters
-            military-early:
-                filter:
-                    kind: [military]
-                    any:
-                        # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: [8], area: { max: 50000000 } }
+                        visible: *icon_visible_landuse_green
+                        priority: 43
+                        text:  { visible: *text_visible_landuse_green }
+                low-priority-early-z11:
+                    filter: { kind_tile_rank: { min: 3 }, $zoom: [11,12] }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { visible: false }
+                low-priority-early-z13:
+                    filter: { kind_tile_rank: { min: 4 }, $zoom: [13] }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { visible: false }
+                peak-labels-later:
+                    filter: { kind: [peak, volcano], $zoom: { min: 14 } }
+                    draw:
+                        icons:
+                            text:
+                                text_source: function() { if( feature.name && feature.elevation ) { return feature.name + "\n" + feature.elevation + "m"; } else { if( feature.name ) { return feature.name; } else { return feature.elevation; } } }
+            waterfall-early:
+                filter: { kind: [waterfall], $zoom: { max: 14 } }
                 draw:
                     icons:
-                        visible: false
-            university-early:
-                filter:
-                    kind: [university, college]
-                    any:
-                        # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: [11], area: { max: 2000000 } }
-                        - { $zoom: [12], area: { max: 500000 } }
+                        visible: *icon_visible_landuse_green
+                        text:  { visible: *text_visible_landuse_green }
+                low-priority-early-z11:
+                    filter: { kind_tile_rank: { min: 3 }, $zoom: [11,12] }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { visible: false }
+                low-priority-early-z13:
+                    filter: { kind_tile_rank: { min: 4 }, $zoom: [13] }
+                    draw:
+                        icons:
+                            visible: false
+                            text: { visible: false }
+            waterfall-labels:
+                filter: { kind: [waterfall], $zoom: { min: 14 } }
                 draw:
                     icons:
-                        visible: false
-            school-early:
-                filter:
-                    kind: [school, kindergarten]
-                    any:
-                        # show labels for smaller landuse areas at higher zooms
-                        - { $zoom: [13], area: { max: 100000 } }
-                        - { $zoom: [14], area: { max: 50000 } }
-                        - { $zoom: [15], area: { max: 10000 } }
-                        - { $zoom: [16], area: { max: 5000 } }
-                        - { $zoom: [17], area: { max: 2000 } }
+                        text:
+                            text_source: function() { if( feature.name && feature.height ) { return feature.name + "\n" + feature.height; } else { if( feature.name ) { return feature.name; } else { return feature.height; } } }
+            drinking-water-early:
+                filter: { kind: [drinking_water], $zoom: { max: 18 } }
                 draw:
                     icons:
                         visible: false
-            garden-area-early:
-                filter:
-                    kind: [garden, allotments]
-                    any:
-                        # limit show smaller landuse areas to higher zooms
-                        - { $zoom: [12], area: { max: 500000 } }
-                        - { $zoom: [13], area: { max: 100000 } }
-                        - { $zoom: [14], area: { max: 10000 } }
-                        - { $zoom: [15], area: { max: 5000 } }
+                        text:  { visible: false }
+            memorial-early:
+                filter: { kind: [memorial], $zoom: { max: 13 } }
                 draw:
                     icons:
                         visible: false
-            cemetery-early:
-                filter:
-                    kind: [cemetery]
-                    # limit show smaller landuse areas to higher zooms
-                    any:
-                        - { $zoom: [12], area: { max: 3000000 } }
+                        text:  { visible: false }
+            animal-points-early:
+                filter: { kind: [animal], area: false, $zoom: { max: 18 } }
                 draw:
                     icons:
                         visible: false
-            golf_course-early:
+                        text:  { visible: false }
+#            animal-areas-early:
+#                filter: { kind: [animal], area: { min: 500 }, $zoom: { max: 18 } }
+#                draw:
+#                    icons:
+#                        visible: false
+#                        text:  { visible: false }
+            parking-labels-early:
                 filter:
-                    kind: golf_course
-                    any:
-                        - { $zoom: [12], area: { max: 2500000 } }
+                    kind: [parking]
+                    $zoom: { max: 18 }
                 draw:
                     icons:
                         visible: false
-            office-early:
+                        text:
+                            visible: false
+            parking-labels:
                 filter:
-                    - { kind: [insurance, office, company], $zoom: [15], area: { max: 10000 } }
-                    - { kind: [insurance, office, company], $zoom: [16], area: { max: 5000 } }
+                    kind: [parking]
+                    $zoom: { min: 18 }
                 draw:
                     icons:
-                        visible: false
-            landuse-labels-green-areas-not-national-park:
-                filter:
-                    kind: [park, conservation, protected_area, nature_reserve, forest, grass]
-                    any:
-                    # show labels for smaller landuse areas at higher zooms
-                    - { $zoom: { max: 6 }, area: true }
-                    - { $zoom: [6],    area: { max: 5000000000 } }
-                    - { $zoom: [7],    area: { max: 5000000000 } }
-                    - { $zoom: [8],    area: { max: 1000000000 } }
-                    - { $zoom: [9],    area: { max: 100000000 } }
-                    - { $zoom: [10],   area: { max: 50000000 } }
-                    - { $zoom: [11],   area: { max: 20000000 } }
-                    - { $zoom: [12],   area: { max: 5000000 } }
-                    - { $zoom: [13],   area: { max: 200000 } }
-                    - { $zoom: [14],   area: { max: 50000 } }
-                    - { $zoom: [15],   area: { max: 5000 } }
-                    - { $zoom: [16],   area: { max: 1000 } }
+                        text:
+                            visible: *text_visible_poi_landuse
+                            font:
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+            landuse-funky:
+                filter: { kind: [commercial, residential, wood], $zoom: { max: 17 } }
                 draw:
                     icons:
                         visible: false
-                wilderness-areas-early:
-                    filter: function() { return $zoom < 9 && feature.name && (feature.name.indexOf("Wilderness") > -1 || feature.name.indexOf("BLM") > -1 || feature.protect_class == '1' || feature.protect_class == '1a' || feature.protect_class == '1b' ); }
+                        text:
+                            visible: false
+            car-sharing:
+                filter: { kind: car_sharing }
+                icons-early:
+                    filter: { $zoom: { max: 17 } }
                     draw:
                         icons:
                             visible: false
-                not-national-park:
-                    filter: function() { return feature.name && !((feature.name.indexOf("National Park") > -1) || feature.name.indexOf("National Monument") > -1); }
-                    early:
-                        filter: { $zoom: { max: 8 } }
-                        draw:
-                            icons:
+                text-labels-early:
+                    filter: { $zoom: { max: 19 } }
+                    draw:
+                        icons:
+                            text:
                                 visible: false
-            landuse-labels-not-any-above:
-                filter:
-                    $zoom: { max: 6 }
-                    not: { kind: [aerodrome, airport, allotments, aquarium, attraction, battlefield, beach, cemetery, college, conservation, forest, garden, glacier, golf_course, grass, kindergarten, landmark, maze, national_park, nature_reserve, park, playground, protected_area, resort, school, stadium, station, theme_park, university, winery, winter_sports, zoo] }
+            bicycle_rental_station-early:
+                filter: { kind: bicycle_rental_station }
+                icons-early:
+                    filter: { $zoom: { max: 17 } }
+                    draw:
+                        icons:
+                            size: [[16, 14px], [17, 16px], [18, 20px]]
+                early-names:
+                    filter: { $zoom: { max: 17 } }
+                    draw:
+                        icons:
+                            text:
+                                visible: false
+            tower:
+                filter: { kind: [tower], label_placement: true }
                 draw:
                     icons:
                         visible: false
-            glacier:
-                filter: { $zoom: { max: 14 }, kind: glacier, area: false }
+                        text:
+                            font:
+                                style: italic
+            station-train-subway:
+                filter: { kind: [station, train_station], $zoom: { min: 11 } }
+                visible: *label_visible_station
                 draw:
                     icons:
-                        visible: false
-
-
-        # set special priority, sprite, and text styles per kind
-        # has-area:
-        #     filter: { area: true }
-        #     draw:
-        #         icons:
-        #             priority: 41
-
-        national-park-protected-areas:
-            filter:
-                kind: national_park
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    sprite: park
-                    priority: 41
-                    text:
-                        visible: global.text_visible_landuse_green
-                        font:
-                            fill: global.text_fill_park
-                            style: italic
-            # large park icon
-            # z14-parks:
-            #     filter: { $zoom: { min: 14 } }
-            #     draw:
-            #         icons:
-            #             sprite: park-l
-            #             size: [[14,24px],[16,32px]]
-        parks:
-            filter:
-                - kind: [park, conservation, grass]
-                - { kind: protected_area, not: { protect_class: [6, '6'] } }
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    sprite: park
-                    priority: 41
-                    text:
-                        visible: global.text_visible_landuse_green
-                        font:
-                            fill: global.text_fill_park
-                            style: italic
-
-            only-text-later:
-                filter: { kind: [grass], $zoom: { min: 16 } }
+                        visible: *icon_visible_station
+                        sprite: train_station
+                        size: [[13, 12px], [14, 12px], [15, 16px], [17, 18px], [18, 20px]]
+                        priority: 41
+                        text:
+                            visible: *text_visible_station
+                            font:
+                                weight: 600
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+                low-priority-early:
+                    filter: { kind_tile_rank: { min: 5 }, $zoom: { min: 0, max: 13 } }
+                    draw:
+                        icons:
+                            visible: false
+                            #size: [[12, 10px], [14, 10px], [15, 16px]]
+                            text: { visible: false }
+                low-priority-early-z13:
+                    filter: { kind_tile_rank: { min: 5 }, $zoom: [13] }
+                    draw:
+                        icons:
+                            visible: false
+                            #size: [[12, 10px], [14, 10px], [15, 16px]]
+                            text: { visible: false }
+                low-priority-early-z14:
+                    filter: { kind_tile_rank: { min: 7 }, $zoom: [14] }
+                    draw:
+                        icons:
+                            #size: [[14, 11px], [15, 16px], [17, 18px], [18, 20px]]
+                            #visible: false
+                            text: { visible: false }
+                stations-later:
+                    filter: { $zoom: { min: 18 } }
+                    draw:
+                        icons:
+                            text:
+                                font:
+                                    size: 11px
+            tram-stop-early:
+                filter: { kind: tram_stop, $zoom: { max: 15 } }
                 draw:
                     icons:
-                        size: 0px
+                        visible: false
                         text:
-                            font:
-                                style: italic
-        forest:
-            filter:
-                - kind: forest
-                - { kind: protected_area, protect_class: [6, '6'] }
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    sprite: forest
-                    priority: 41
-                    text:
-                        visible: global.text_visible_landuse_green
-                        font:
-                            fill: global.text_fill_park
-                            style: italic
-#        wilderness-nature_reserve:
-#            filter:
-#                - kind: nature_reserve
-#            draw:
-#                icons:
-#                    visible: global.icon_visible_landuse_green
-#                    size: global.icon_size_green
-#                    sprite: forest
-#                    priority: 41
-#                    text:
-#                        visible: global.text_visible_landuse_green
-#                        font:
-#                            fill: global.text_fill_park
-#                            style: italic
-
-        beach:
-            filter:
-                kind: [beach]
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    text:
-                        visible: global.text_visible_landuse_green
-                        font:
-                            fill: global.text_fill_beach
-        airport:
-            filter:
-                kind: [airport, aerodrome]
-            draw:
-                icons:
-                    visible: global.icon_visible_landuse_green
-                    size: global.icon_size_green
-                    priority: 42
-                    text:
-                        visible: global.text_visible_landuse_green
-                        text_source: global.ux_language_text_source_iata
-            early:
-                filter: { $zoom: [9,10,11] }
-                draw: { icons: { text: { text_source: iata } } }
-            early2:
-                filter: { $zoom: { min: 12 } }
-                draw: { icons: { text: { font: { size: 11px } } } }
-        enclosure-related:
-            filter:
-                kind: [enclosure, animal]
-            draw:
-                icons:
-                    priority: 43
-                    size: 0px
-                    #: dot-black
-                    text:
-                        text_wrap: 10
-                        font:
-                            style: italic
-                            weight: normal
-        glacier:
-            filter:
-                kind: glacier
-            draw:
-                icons:
-                    size: 0px
-                    #visible: false
+                            visible: false
+            tram-stop-early-z15:
+                filter: { kind: tram_stop, $zoom: [15] }
+                draw:
+                    icons:
+                        text:
+                            visible: false
+            tram-stop:
+                filter: { kind: tram_stop, $zoom: { min: 15 } }
+                draw:
+                    icons:
+                        size: [[16, 12px], [17, 18px]]
+            glaciers-pois:
+                filter: { $zoom: { min: 14 }, kind: glacier, area: false }
+                draw:
+                    icons:
+                        visible: false
+                        text:
+                            visible: false
                     text:
-                        visible: true
-                        priority: 44
+                        visible: false
+                        priority: 45
                         text_wrap: 10
                         font:
-                            weight: normal
+                            weight: 400
                             style: italic
-                            fill: global.text_fill_park
-
-        # landuse-labels-not-any-above:
-        #     filter:
-        #         not: { kind: [aerodrome, airport, allotments, aquarium, attraction, battlefield, beach, cemetery, college, conservation, forest, garden, glacier, golf_course, grass, kindergarten, landmark, maze, national_park, nature_reserve, park, playground, protected_area, resort, school, stadium, station, theme_park, university, winery, winter_sports, zoo] }
-        #     draw:
-        #         icons:
-        #             priority: 43
-
-        building-like:
-            filter: { kind: [commercial,residential,warehouse,public,dormitory], osm_relation: false }
-            draw:
-                icons:
-                    sprite: building
-
-        station-train-subway:
-            filter: { kind: [station, train_station] }
-            draw:
-                icons:
-                    visible: global.icon_visible_station
-                    size: [[13, 12px], [14, 12px], [15, 16px], [17, 18px], [18, 20px]]
-                    priority: 44
-                    text:
-                        visible: global.text_visible_station
-            station-early:
+                            fill: '#4ba3c5'
+            bus-stop-bus-station-labels:
                 filter:
-                    $zoom: { max: 11 }
+                    kind: [bus_stop, bus_station]
+                    $zoom: { min: 18 }
                 draw:
                     icons:
-                        visible: false
-            # for a transit style we'd want to see **all**, so don't move this above (it's special to this style)
-            low-priority-early:
-                filter: { kind_tile_rank: { min: 5 }, $zoom: { min: 0, max: 13 } }
+                        size: [[17, 8px], [19, 18px]]
+                        text:
+                            visible: *text_visible_poi_landuse
+                            font:
+                                size: 10px
+                                stroke: { color: *text_stroke, width: 4 }
+            bus_stop-early:
+                filter:
+                    kind: [bus_stop]
+                    $zoom: { max: 17 }
                 draw:
                     icons:
                         visible: false
-            low-priority-early-z13:
-                filter: { kind_tile_rank: { min: 5 }, $zoom: [13] }
+                        text:
+                            visible: false
+            bus_stop-early-z17:
+                filter:
+                    kind: [bus_stop]
+                    $zoom: [17,18]
+                draw:
+                    icons:
+                        size: [[17, 16px], [19, 18px]]
+                        text:
+                            visible: false
+            minor-z17-early:
+                filter:
+                    kind: [accountant, administrative, advertising_agency, architect, association, atm, bakery, bed_and_breakfast, bicycle, bicycle_parking, bicycle_rental_station, books, bus_stop, butcher, car, car_repair, chalet, clothes, company, computer, consulting, convenience, doityourself, drinking_water, dry_cleaning, educational_institution, emergency_phone, employment_agency, estate_agent, fashion, financial, florist, foundation, gate, gift, government, greengrocer, guest_house, hairdresser, hostel, hotel, insurance, it, jewelry, lawyer, mast, memorial, mobile_phone, motel, newspaper, ngo, notary, optician, parking, pet, physician, playground, political_party, post_box, religion, research, subway_entrance, tax_advisor, telecommunication, telephone, theatre, therapist, toilets, traffic_signals, travel_agent, water_tower, true]
+                    area: false
+                    $zoom: { max: 17 }
                 draw:
                     icons:
                         visible: false
-            low-priority-early-z14:
-                filter: { kind_tile_rank: { min: 7 }, $zoom: [14] }
+                        text:  { visible: false }
+            minor-z18-early:
+                filter:
+                    kind: [bench, waste_basket]
+                    area: false
+                    $zoom: { max: 18 }
                 draw:
                     icons:
-                        text: { visible: false }
-
-        tram-stop-early:
-            filter: { kind: tram_stop, $zoom: { max: 15 } }
-            draw:
-                icons:
-                    visible: false
-                    text:
                         visible: false
-        tram-stop:
-            filter: { kind: tram_stop, $zoom: { min: 15 } }
-            draw:
-                icons:
-                    size: [[16, 12px], [17, 18px]]
-
-        garden-no-area-early:
-            filter: { kind: [garden, allotments], $zoom: [16], area: false }
-            draw:
-                icons:
-                    priority: 45
-                    size: 14px
-                    text:  { font: { size: 10px, style: italic } }
-        garden-no-area-later:
-            filter: { kind: [garden, allotments], $zoom: { min: 17 }, area: false }
-            draw:
-                icons:
-                    priority: 45
-                    size: 16px
-                    text:  { font: { size: 11px, style: italic } }
-        gate:
-            filter: { kind: gate, name: true  }
-            draw: { icons: { sprite: generic } }
-
-        parking-labels:
-            filter:
-                kind: [parking]
-                $zoom: { min: 18 }
-            draw:
-                icons:
-                    text:
-                        visible: global.text_visible_poi_landuse
-                        font:
-                            size: 10px
-        tower:
-            filter: { kind: [tower], label_placement: true }
-            draw:
-                icons:
-                    size: 0px
-                    #visible: false
-                    text:
-                        font:
-                            style: italic
-
-        # TODO: this isn't working, should see small icons near the transbay terminal in SF
-        bus_stop:
-            filter:
-                kind: [bus_stop]
-            draw:
-                icons:
-                    size: 14px
-                    text:
-                        font:
-                            size: 11px
-                            weight: normal
-            later:
-                filter: { $zoom: { max: 19 } }
+                        text:  { visible: false }
+            outdoor-needing-icons:
+                filter: { kind: [boat_rental,bicycle_repair_station, cycle_barrier, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, communications_tower, putin, egress, hazard, put_in_egress, rapid, beacon, cross, mineshaft, adit, water_well, saddle, dune, sinkhole, rock, stone, bicycle_junction, walking_junction, dam, boat_storage, windmill, fishing, recreation_track, horse, fire_lookout, fee_station, rest_area] }
                 draw:
                     icons:
+                        order: 41
+                        sprite: generic
                         text:
-                            visible: false
-
-        airport-gate:
-            filter: { kind: aeroway_gate }
-            draw:
-                icons:
-                    visible: false
-                text-blend-order:
-                    visible: global.text_visible_airport_gate
-                    text_source: ref
-                    priority: 63
-                    font:
-                        fill: global.text_fill_exits
-                        size: [[16,9px],[17,12px],[20,14px]]
-            later:
-                filter: { $zoom: { min: 19 } }
+                            order: 42
+            outdoor-has-icons:
+                filter: { kind: [outdoor, lighthouse, saddle, picnic_area, picnic_table, camp_site, ski, mine, zoo, museum, gas, gas_canister, slipway, mineshaft, adit, recreation_track, playground, allotments, attraction, landmark] }
                 draw:
                     icons:
+                        order: 41
                         text:
-                            font:
-                                weight: 600
-
-        highway-exit:
-            filter: { kind: motorway_junction, $zoom: { min: 16 } }
-            draw:
-                icons:
-                    visible: false
-                text-blend-order:
-                    visible: global.text_visible_exits
-                    text_source: ref
-                    priority: 63
-                    font:
-                        fill: global.text_fill_exits
-                        size: [[12,9px],[15,12px],[17,14px]]
-                        stroke: { color: global.text_stroke, width: [[12,2px],[14,3px],[15,3px]] }
-            later:
-                filter: { $zoom: { min: 16 } }
+                            order: 42
+            not-outdoor-not-landuse:
+                filter: { area: false, not: { kind: [park, national_park, outdoor, bicycle_repair_station, life_ring, waste_disposal, watering_place, water_point, lifeguard_tower, power_pole, power_tower, petroleum_well, bicycle_junction, walking_junction, dam, boat_storage, windmill, playground, allotments, attraction, landmark] } }
+                draw:
+                    icons:
+                        order: 45
+                        text:
+                            order: 46
+            suppress-early:
+                filter: { $zoom: { max: 15 }, kind: [scrub, wetland, scree, meadow, grass, farmyard, farmland, wood, pier, breakwater, groyne, dike, cutline, residential, retail, commercial, industrial] }
                 draw:
                     icons:
+                        visible: false
+                    text:
+                        visible: false
+                meadow:
+                    filter: { kind: [meadow], $zoom: [14] }
+                    draw:
                         text:
+                            visible: true
+                            text_wrap: 10
                             font:
-                                weight: 600
-
-
+                                style: italic
+            suppress-the-icon-text-label-only:
+                filter: { $zoom: { min: 15 }, kind: [scrub, wetland, scree, meadow, village_green, common, grass, farmyard, farmland, wood, enclosure, animal, pier, breakwater, groyne, dike, cutline, residential, retail, commercial, industrial] }
+                draw:
+                    icons:
+                        visible: false
+                    text:
+                        visible: true
+                        text_wrap: 10
+                        font:
+                            style: italic
+            icons:
+                building-icon:
+                    filter: { kind: [building, auditorium, terminal, hangar, retirement_home, manor, recreation_center, apartments] }
+                    draw:   { icons: { sprite: building } }
+                    early:
+                       filter:
+                           any:
+                               # show labels for smaller landuse areas at higher zooms
+                               - { $zoom: [14], area: { max: 200000 } }
+                               - { $zoom: [15], area: { max: 20000 } }
+                               - { $zoom: [16], area: { max: 5000 } }
+                               - { $zoom: [17], area: { max: 1000 } }
+                       draw:
+                           icons:
+                               visible: false
+                               text:
+                                   visible: false
+                college:
+                    filter: { kind: [university, college], area: false }
+                    draw:   { icons: { sprite: college } }
+                dam:
+                    filter: { kind: [dam] }
+                    draw:   { icons: { sprite: dam } }
+                hardware-store:
+                    filter: { kind: [hardware, hardware-store, doityourself, paint] }
+                    draw:   { icons: { sprite: hardware-store } }
+                hotel:
+                    filter: { kind: [hotel, motel, hostel] }
+                    draw:   { icons: { sprite: hotel } }
+                landmark:
+                    filter: { kind: [landmark, memorial, monument, wayside_shrine, beacon] }
+                    draw:   { icons: { sprite: landmark } }
+                tower:
+                    filter: { kind: [tower], label_placement: false }
+                    draw:   { icons: { sprite: landmark } }
+                # prefix with "a-" here to allow Tangram to sort the generic style 1st, allowing more specific religion tags to win later
+                place_of_worship:
+                    filter:
+                        all:
+                            - kind: [place_of_worship, wayside_chapel]
+                    draw:
+                        icons:
+                            sprite: function() { return feature.religion; }
+                            sprite_default: place_of_worship
     water-area-labels:
         data: { source: mapzen, layer: [water] }
-        visible: global.text_visible_water_labels
+        visible: *text_visible_water_labels
         filter:
             all:
                 - name: true
@@ -5048,8 +5706,8 @@ layers:
                 text-blend-order:
                     text_source: global.ux_language_text_source
                     font:
-                        fill: global.text_fill_water
-                        family: global.text_font_family
+                        fill: *text_fill_water
+                        family: *text_font_family
                         style: italic
                         weight: 400
                         size: 12px
@@ -5069,14 +5727,14 @@ layers:
 
     ocean-sea-labels:
         data: { source: mapzen, layer: water }
-        visible: global.text_visible_water_labels
+        visible: *text_visible_water_labels
         filter: { name: true, kind: [sea, ocean] }
         draw:
             text-blend-order:
                 text_source: global.ux_language_text_source
                 font:
-                    fill: global.text_fill_water
-                    family: global.text_font_family
+                    fill: *text_fill_water
+                    family: *text_font_family
                     weight: normal
                     size: 12px
                     transform: uppercase
@@ -5128,14 +5786,14 @@ layers:
             filter: { kind: [continent], $zoom: {max: 5} }
             draw:
                 text-blend-order:
-                    visible: global.text_visible_continent
+                    visible: *text_visible_continent
                     text_source: global.ux_language_text_source_continent_stacked_only
                     text_wrap: false
                     font:
-                        family: global.text_font_family
+                        family: *text_font_family
                         size: [[1,11px],[3,14px]]
                         style: italic
-                        fill: global.text_fill
+                        fill: *text_fill
                         weight: normal
                         transform: uppercase
             continent-spacer:
@@ -5147,68 +5805,23 @@ layers:
             filter: { kind: [archipelago, island, islet] }
             draw:
                 text-blend-order:
-                    visible: global.text_visible_island
+                    visible: *text_visible_island
                     text_wrap: 10
                     font:
-                        family: global.text_font_family
+                        family: *text_font_family
                         size: 12px
                         style: italic
-                        fill: global.text_fill
+                        fill: *text_fill
                         weight: normal
-                        stroke: { color: global.text_stroke, width: 4 }
+                        stroke: { color: *text_stroke, width: 4 }
                         #transform: uppercase
 
     landuse:
-        data: { source: mapzen, layer: landuse }
+        data: { source: mapzen }
         draw:
             terrain:
                 order: function() { return feature.sort_rank; }
                 visible: false
-
-        landuse-labels:
-            filter:
-                all:
-                    - label_placement: true
-                    - name: true
-            draw:
-                text-blend-order:
-                    text_source: global.ux_language_text_source
-                    interactive: global.interactive
-                    move_into_tile: true
-                    priority: 100
-                    visible: global.text_visible_landuse_generic
-                    font:
-                        fill: '#666'
-                        family: global.text_font_family
-                        style: italic
-                        size: 11px
-                        stroke: { color: global.text_stroke_address, width: 1 }
-
-            show-with-icon:
-                filter: { kind: [allotments] }
-                draw:
-                    text-blend-order:
-                        visible: false
-                    icons:
-                        visible: global.icon_visible_poi_landuse
-                        size: [[13, 18px], [16, 18px], [18, 22px]]
-                        sprite: function() { return feature.kind; }
-                        sprite_default: generic
-                        interactive: global.interactive
-                        priority: 65 #function() { return (feature.min_zoom && Math.floor(feature.min_zoom * 1000)) || 65; }
-                        repeat_group: abc
-                        buffer: 7px
-                        text:
-                            visible: global.text_visible_poi_landuse
-                            text_source: global.ux_language_text_source
-                            text_wrap: 18
-                            max_lines: 3
-                            font:
-                                family: global.text_font_family
-                                weight: 600
-                                fill: [0.10,0.10,0.10]
-                                size: [[13,10px],[14,10px],[18,11px]]
-                                stroke: { color: global.text_stroke, width: 3 }
         tier1:
             # filter:
             #     any:
@@ -5287,7 +5900,7 @@ layers:
                         visible: true
                     # outline:
                     #     style: lines
-                    #     color: global.green6
+                    #     color: *green6
                     #     width: [[9,0px],[10,2px],[12,4px]]
 
             national_forest_level_6:
@@ -5299,7 +5912,7 @@ layers:
                         - operator: ['United States Forest Service']
                 draw:
                     terrain:
-                        color: [0.945,0.995,0.945] #global.green7
+                        color: [0.945,0.995,0.945] #*green7
                         visible: true
 
             parks-and-national-forests-not-national-park:
@@ -5335,7 +5948,7 @@ layers:
                 draw:
                     polygons:
                         color: [1.00,1.00,1.00]
-                        visible: global.green4_v
+                        visible: *green4_v
             forest:
                 filter: { kind: [forest, wood, natural_wood, natural_forest, natural_park], $zoom: { min: 10 }, not: { operator: [ "United States Forest Service"] } }
                 draw:
@@ -5372,11 +5985,11 @@ layers:
 
             # urban:
             #     filter: { kind: [urban, rural, residential] }
-            #     visible: global.earth2_v
+            #     visible: *earth2_v
             #     draw:
             #         polygons:
             #             color: [1.00,1.00,1.00]
-            #             visible: global.earth2_v
+            #             visible: *earth2_v
         tier3:
             # filter:
             #     any:
@@ -5396,21 +6009,21 @@ layers:
                     kind: aerodrome
                 draw:
                     terrain:
-                        color: global.gray-all
-                        visible: global.purple_v
+                        color: *gray-all
+                        visible: *purple_v
             military:
                 filter:
                     kind: military
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
             university:
                 filter:
                     kind: [university, college]
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
         tier4:
             # filter:
@@ -5451,20 +6064,20 @@ layers:
                     kind: industrial
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
             power:
                 filter: { kind: [plant, generator, substation] }
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
             railway:
                 filter:
                     kind: railway
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
         # IGNORE THIS FOR NOW
         #     sports_centre:
@@ -5485,7 +6098,7 @@ layers:
                     kind: stadium
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
             zoo:
                 filter:
@@ -5500,12 +6113,12 @@ layers:
                 draw:
                     terrain:
                         color: [1.0,1.0,1.0]
-                        visible: global.grey8_v
+                        visible: *grey8_v
             man-made:
                 filter: { kind: [pier,wastewater_plant,works,bridge,tower,breakwater,water_works,groyne,dike,cutline] }
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
                 pier:
                     filter: { kind: [pier,bridge,breakwater,groyne,dike,cutline] }
@@ -5517,7 +6130,7 @@ layers:
                 filter: { kind: camp_site }
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
 
         tier5:
@@ -5550,7 +6163,7 @@ layers:
                         - maze
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
             beach:
                 filter:
@@ -5587,8 +6200,8 @@ layers:
                         - { $zoom: { min: 15 }, area: { min: 5000 } }
                 draw:
                     terrain:
-                        color: global.gray-all
-                        visible: global.grey1_v
+                        color: *gray-all
+                        visible: *grey1_v
                 early:
                     filter: { $zoom: { max: 15 } }
                     draw:
@@ -5601,7 +6214,7 @@ layers:
             draw:
                 terrain:
                     color: [0.945,0.995,0.945]
-                    visible: global.grey1_v
+                    visible: *grey1_v
             green-stuff:
                 filter:
                     surface: [grass]
@@ -5624,6 +6237,8 @@ layers:
             draw:
                 terrain:
                     color: [0.808,0.962,0.951]
+                    # color: [0.702,0.949,0.932]
+                    # color: [0.975,0.975,0.828]
                     visible: true
             farmland_friends:
                 filter: { kind: [farmland] }
@@ -5650,6 +6265,7 @@ layers:
             draw:
                 terrain:
                     color: [0.930,0.973,0.980]
+                    # color: [0.975,0.975,0.828]
                     visible: true
         scrub:
             filter:
@@ -5672,6 +6288,7 @@ layers:
             draw:
                 terrain:
                     color: [1.000,0.953,0.900]
+                    # color: [0.975,0.975,0.828]
                     visible: true
             later:
                 filter: { $zoom: { min: 15 } }
@@ -5685,8 +6302,8 @@ layers:
                     kind: place_of_worship
                 draw:
                     terrain:
-                        color: global.gray-all
-                        visible: global.grey1_v
+                        color: *gray-all
+                        visible: *grey1_v
             playground:
                 filter:
                     kind: playground
@@ -5699,7 +6316,7 @@ layers:
                     kind: school
                 draw:
                     terrain:
-                        color: global.gray-all
+                        color: *gray-all
                         visible: true
 
             minor-landuse:
@@ -5793,7 +6410,7 @@ layers:
         draw:
             lines:
                 color: [[11,[0.408,0.741,0.690]],[15,[0.131,0.667,0.575]]] #[11,[0.252,0.509,0.60]],[12,[0.120,0.600,0.520]]
-            dashed_small:
+            dashedline:
                 color: [0.120,0.600,0.520]
             dots-lines:
                 color: [0.120,0.600,0.520]
@@ -5849,12 +6466,12 @@ layers:
                 draw:
                     text-blend-order:
                         priority: 58
-                        visible: global.text_visible_path
+                        visible: *text_visible_path
                         font:
                             fill: [0.143,0.544,0.481]
                             # fill: [0.256,0.570,0.565]
                             size: 12px
-                            stroke: { color: global.text_stroke, width: 4 }
+                            stroke: { color: *text_stroke, width: 4 }
                 in_zoo_golf_course:
                     filter: { landuse_kind: [zoo, golf_course, garden, university, cemetery, allotments], $zoom: { max: 15 } }
                     draw:
@@ -5881,7 +6498,7 @@ layers:
                     width: [[13, 0.75px], [14, 0.6px], [15, 1px], [16, 2px], [17, 3px], [18, 4px], [19, 4px]]
                     visible: true
                     #color: purple
-                dashed_small:
+                dashedline:
                     order: 1005
             early-show-as-lines-z14:
                 filter: { $zoom: { max: 15 } }
@@ -5968,7 +6585,7 @@ layers:
                         order: 350 # function() { return feature.sort_rank; }
                     dots-lines:
                         order: 351 # function() { return (feature.sort_rank + 1); }
-                    dashed_small:
+                    dashedline:
                         visible: false
                 early-z17:
                     filter: { $zoom: { max: 18 } }
@@ -5988,11 +6605,11 @@ layers:
                 draw:
                     text-blend-order:
                         priority: 58
-                        visible: global.text_visible_path
+                        visible: *text_visible_path
                         font:
                             fill: [0.143,0.544,0.481]
                             size: 12px
-                            stroke: { color: global.text_stroke, width: 4 }
+                            stroke: { color: *text_stroke, width: 4 }
                 in_zoo_golf_course:
                     filter: { landuse_kind: [zoo, golf_course, garden, university, cemetery, allotments], $zoom: { max: 15 } }
                     draw:
@@ -6046,11 +6663,11 @@ layers:
                 draw:
                     text-blend-order:
                         priority: 58
-                        visible: global.text_visible_path
+                        visible: *text_visible_path
                         font:
                             fill: [0.120,0.600,0.520]
                             size: 12px
-                            stroke: { color: global.text_stroke, width: 4 }
+                            stroke: { color: *text_stroke, width: 4 }
 
     track-overlay:
         data: { source: mapzen, layer: roads }
@@ -6109,11 +6726,11 @@ layers:
             draw:
                 text-blend-order:
                     priority: 58
-                    visible: global.text_visible_path
+                    visible: *text_visible_path
                     font:
                         fill: [0.536,0.451,0.378]
                         size: 12px
-                        stroke: { color: global.text_stroke, width: 4 }
+                        stroke: { color: *text_stroke, width: 4 }
             in_zoo_golf_course-early:
                 filter: { landuse_kind: [zoo, golf_course, garden, university, cemetery, allotments], $zoom: { max: 15 } }
                 draw:
@@ -6148,11 +6765,11 @@ layers:
             draw:
                 text-blend-order:
                     priority: 58
-                    visible: global.text_visible_path
+                    visible: *text_visible_path
                     font:
                         fill: [0.536,0.451,0.378]
                         size: 12px
-                        stroke: { color: global.text_stroke, width: 4 }
+                        stroke: { color: *text_stroke, width: 4 }
 
 
     other-roads-walking-network-only:
@@ -6179,6 +6796,16 @@ layers:
                     outline:
                         color: [0.120,0.600,0.520]
                         width: [[15, 0.5px],[16, 1.5px],[17, 1.5px],[18, 2.5px],[19, 1m]]
+                casing_left:
+                    visible: false
+                    order: 486
+                    color: [0.120,0.600,0.520]
+                    width: [[15, 0.5px],[16, 5.5px],[17, 10px],[18, 9m],[19, 8m]]
+                casing_right:
+                    visible: false
+                    order: 486
+                    color: white
+                    width: [[15, 0.5px],[16, 6px],[17, 10px],[18, 9m],[19, 8m]]
         the_network:
             draw:
                 lines:
@@ -6202,12 +6829,11 @@ layers:
     transit-overlay-rail-lines:
         data: { source: mapzen, layer: transit }
         filter:
-            all:
-                - not: { kind: [platform, railway] }
-                - function() { return global.sdk_transit_overlay; }
+            not: { kind: [platform, railway] }
         draw:
             lines:
                 order: 499
+                visible: global.sdk_transit_overlay
                 color: purple
                 width: [[5,1.5px],[6,2px],[11,3px],[18,4px]]
                 outline:
@@ -6289,99 +6915,36 @@ layers:
                 draw:
                     lines:
                         order: 504
+        labels-transit-lines-early:
+            filter: { $zoom: [13,14], ref: true }
+            draw:
+                text:
+                    visible: global.sdk_transit_overlay
+                    priority: 20
+                    text_source: function() { if( feature.ref.length < 4 ) { return feature.ref; } else { return ''; } }
+                    font:
+                        fill: black
+                        size: 12px
+                        weight: bold
+                        stroke: { color: white, width: 2 }
         labels-transit-lines:
-            filter:
-                all:
-                    - function() { return global.sdk_transit_overlay; }
-                    - all:
-                        - $zoom: { min: 13 }
-                        - ref: true
+            filter: { $zoom: { min: 15 } }
             draw:
-                icons:
+                text:
+                    visible: global.sdk_transit_overlay
                     priority: 20
-                    # you need to match any custom shield to the vector tile `network` values
-                    sprite: function() { return ('sdk_shield-' + feature.ref.length + 'char'); }
-                    sprite_default: sdk_shield_5char
-                    color: function() { if ( feature.kind === 'train') { return 'purple' } else { return feature.colour || 'purple'; } }
-                    # Size is specified below, and limited to 5 char in another filter
-                    repeat_group: shields
-                    repeat_distance: [[8,90px],[10,40px],[13,30px]]
-                    placement: midpoint
-                    placement_min_length_ratio:
-                        - [8, 0.1]
-                        - [9, 0.25]
-                        - [10, 0.25]
-                        - [11, 0.15]
-                        - [12, 1]
-                        - [13, 1.50]
-                        - [14, 2.0]
-                    cull_from_tile: true
-#                    visible: false
-                    text:
-                        offset: [0px, -0.5px]
-                        repeat_distance: 200px
-                        anchor: center
-                        text_source: function() { if( feature.ref.length < 6 ) { return feature.ref; } else { return ''; } }
-                        font:
-                            family: Montserrat
-                            fill: function() { if(feature.colour == 'yellow') { return '#555'; } else { return 'white'; } }
-                            style: bold
-                            size: [[7,7px],[12,8px],[16,11px]]
-
-            width_1char:
-                filter: function() { return (feature.ref.length === 1); }
-                draw:
-                    icons:
-                        size: [[6,[16px,16px]],[13,[18px,18px]],[16,[21px,21px]]]
-            width_2char:
-                filter: function() { return (feature.ref.length === 2); }
-                draw:
-                    icons:
-                        size: [[6,[21px,16px]],[13,[24px,18px]],[16,[28px,21px]]]
-            width_3char:
-                filter: function() { return (feature.ref.length === 3); }
-                draw:
-                    icons:
-                        size: [[6,[27px,16px]],[13,[31px,18px]],[16,[36px,21px]]]
-            width_4char:
-                filter: function() { return (feature.ref.length === 4); }
-                draw:
-                    icons:
-                        size: [[6,[32px,16px]],[13,[36px,18px]],[16,[41px,21px]]]
-                # London sucks
-                early:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        icons:
-                            visible: false
-            width_5char:
-                filter: function() { return (feature.ref.length === 5); }
-                draw:
-                    icons:
-                        size: [[6,[37px,16px]],[13,[41px,18px]],[16,[48px,21px]]]
-                # London sucks
-                early:
-                    filter: { $zoom: { max: 14 } }
-                    draw:
-                        icons:
-                            visible: false
-            # this is kinda a hack
-            width_longggggg:
-                filter: function() { return (feature.ref.length > 5); }
-                draw:
-                    icons:
-                        visible: false
-
-        z19-show-long-route-name:
-                filter:
-                    all:
-                        - function() { return global.sdk_transit_overlay; }
-                        - $zoom: { min: 19 }
+                    text_source: ref
+                    font:
+                        fill: black
+                        size: 14px
+                        weight: bold
+                        stroke: { color: white, width: 2 }
+            z19-show-long-route-name:
+                filter: { $zoom: { min: 19 } }
                 draw:
                     text:
+                        text_source: function() { return feature.route_name || feature.ref; }
                         font:
-                            fill: black
-                            style: italic
                             stroke: { color: white, width: 3px }
 
 #    transit-bus-roads:
@@ -6615,4 +7178,4 @@ layers:
 #                        color: '#bc8f96'
 #                        width: [[15,0px],[16,0.5px],[17,1px],[19,2px]]
 #                lines:
-#                    visible: false
+#                    visible: false
\ No newline at end of file
index 4096d74..1d7af6f 100644 (file)
@@ -28,6 +28,7 @@ extern "C" {
 
 int mapzen_init()
 {
+       TangramView::initNetworkRequests();
        int ret = mapzen_init_queue();
 
        return ret;
@@ -35,6 +36,7 @@ int mapzen_init()
 
 int mapzen_shutdown()
 {
+       TangramView::deinitNetworkRequests();
        int ret = mapzen_deinit_queue();
 
        return ret;
diff --git a/src/mapzen/tangram/ease.h b/src/mapzen/tangram/ease.h
new file mode 100644 (file)
index 0000000..ed9cb81
--- /dev/null
@@ -0,0 +1,39 @@
+#pragma once
+
+#include "tangram.h"
+#include <cmath>
+#include <functional>
+
+namespace Tangram {
+
+using EaseCb = std::function<void (float)>;
+
+template<typename T>
+T ease(T _start, T _end, float _t, EaseType _e) {
+    float f = _t;
+    switch (_e) {
+        case EaseType::cubic: f = (-2 * f + 3) * f * f; break;
+        case EaseType::quint: f = (6 * f * f - 15 * f + 10) * f * f * f; break;
+        case EaseType::sine: f = 0.5 - 0.5 * cos(M_PI * f); break;
+        default: break;
+    }
+    return _start + (_end - _start) * f;
+}
+
+struct Ease {
+    float t;
+    float d;
+    EaseCb cb;
+
+    Ease() : t(0), d(0), cb([](float) {}) {}
+    Ease(float _duration, EaseCb _cb) : t(-1), d(_duration), cb(_cb) {}
+
+    bool finished() const { return t >= d; }
+
+    void update(float _dt) {
+        t = t < 0 ? 0 : std::fmin(t + _dt, d);
+        cb(std::fmin(1, t / d));
+    }
+};
+
+}
index 4f2c91b..9bb8589 100644 (file)
@@ -1,85 +1,73 @@
 #pragma once
 
-#include <functional>
 #include <string>
+#include <cstring>
 #include <vector>
+#include <algorithm>
+#include <functional>
+#include <cstdio>
 
-namespace Tangram {
-
-// Function type for a mapReady callback
-using MapReady = std::function<void(void*)>;
-
-// Function type for receiving data from a successful network request
-using UrlCallback = std::function<void(std::vector<char>&&)>;
-
-using FontSourceLoader = std::function<std::vector<char>()>;
-
-struct FontSourceHandle {
-    FontSourceHandle(std::string _path) : path(_path) {}
-    FontSourceHandle(FontSourceLoader _loader) : load(_loader) {}
-
-    std::string path;
-    FontSourceLoader load;
-};
-
-// Print a formatted message to the console
-// Uses printf syntax to write a string to stderr (or logcat, on Android)
+/* Print a formatted message to the console
+ *
+ * Uses printf syntax to write a string to stderr (or logcat, on Android)
+ */
 void logMsg(const char* fmt, ...);
 
-void initGLExtensions();
-
-// Set the priority of the current thread. Priority is equivalent to pthread niceness
-void setCurrentThreadPriority(int priority);
-
-class Platform {
-
-public:
-
-    Platform();
-    virtual ~Platform();
-
-    // Request that a new frame be rendered by the windowing system
-    virtual void requestRender() const = 0;
-
-    // If called with 'true', the windowing system will re-draw frames continuously;
-    // otherwise new frames will only be drawn when 'requestRender' is called.
-    virtual void setContinuousRendering(bool _isContinuous);
-
-    virtual bool isContinuousRendering() const;
+/* Function type for a mapReady callback*/
+using MapReady = std::function<void(void*)>;
 
-    virtual std::string resolveAssetPath(const std::string& path) const;
+/* Request that a new frame be rendered by the windowing system
+ */
+void requestRender();
 
-    // Read a file as a string
   // Opens the file at the _path and returns a string with its contents.
-    // If the file cannot be found or read, the returned string is empty.
-    virtual std::string stringFromFile(const char* _path) const;
+/* If called with 'true', the windowing system will re-draw frames continuously;
* otherwise new frames will only be drawn when 'requestRender' is called.
+ */
+void setContinuousRendering(bool _isContinuous);
 
-    // Read a file into memory
-    // Opens the file at _path then allocates and returns a pointer to memory
-    // containing the contents of the file. The size of the memory in bytes is written to _size.
-    // If the file cannot be read, nothing is allocated and nullptr is returned.
-    virtual std::vector<char> bytesFromFile(const char* _path) const;
+bool isContinuousRendering();
 
-    // Start retrieving data from a URL asynchronously
-    // When the request is finished, the callback _callback will be
-    // run with the data that was retrieved from the URL _url
-    virtual bool startUrlRequest(const std::string& _url, UrlCallback _callback) = 0;
+/* get system path of a font file */
+std::string systemFontPath(const std::string& _name, const std::string& _weight, const std::string& _face);
 
-    // Stop retrieving data from a URL that was previously requested
-    virtual void cancelUrlRequest(const std::string& _url) = 0;
+/* Read a file as a string
+ *
+ * Opens the file at the _path and returns a string with its contents.
+ * If the file cannot be found or read, the returned string is empty.
+ */
+std::string stringFromFile(const char* _path);
 
-    virtual std::vector<char> systemFont(const std::string& _name, const std::string& _weight, const std::string& _face) const;
+/* Read a file into memory
+ *
+ * Opens the file at _path then allocates and returns a pointer to memory
+ * containing the contents of the file. The size of the memory in bytes is written to _size.
+ * If the file cannot be read, nothing is allocated and nullptr is returned.
+ */
+unsigned char* bytesFromFile(const char* _path, size_t& _size);
 
-    virtual std::vector<FontSourceHandle> systemFontFallbacksHandle() const;
+/* Function type for receiving data from a successful network request */
+using UrlCallback = std::function<void(std::vector<char>&&)>;
 
-protected:
+/* Start retrieving data from a URL asynchronously
+ *
+ * When the request is finished, the callback @_callback will be
+ * run with the data that was retrieved from the URL @_url
+ */
+bool startUrlRequest(const std::string& _url, UrlCallback _callback);
 
-    bool bytesFromFileSystem(const char* _path, std::function<char*(size_t)> _allocator) const;
+/* Stop retrieving data from a URL that was previously requested
+ */
+void cancelUrlRequest(const std::string& _url);
 
-private:
 
-    bool m_continuousRendering;
+/* Set the priority of the current thread. Priority is equivalent
+ * to pthread niceness.
+ */
+void setCurrentThreadPriority(int priority);
 
-};
+/* Get the font fallback ordered by importance, 0 being the first fallback
+ * (e.g. the fallback more willing resolve the glyph codepoint)
+ */
+std::string systemFontFallbackPath(int _importance, int _weightHint);
 
-} // namespace Tangram
+void initGLExtensions();
index 1b6fb14..f286cc4 100644 (file)
@@ -1,65 +1,14 @@
-#if 0
 #pragma once
 
 #include "platform.h"
-
-bool shouldRender();
-
-void initUrlRequests(const char* proxyAddress);
-void stopUrlRequests();
-
-#endif
-
-#pragma once
-
-#include "platform.h"
-#include "urlClient.h"
-
 #include <functional>
 #include <Evas_GL.h>
 
-typedef struct _FcConfig    FcConfig;
-
-namespace Tangram {
-
-void setEvasGlAPI(Evas_GL_API *glApi);
-
-class TizenPlatform : public Platform {
-
-public:
-
-    TizenPlatform();
-    TizenPlatform(UrlClient::Options urlClientOptions);
-    ~TizenPlatform() override;
-    void requestRender() const override;
-    bool startUrlRequest(const std::string& _url, UrlCallback _callback) override;
-    void cancelUrlRequest(const std::string& _url) override;
-
-
-    std::vector<FontSourceHandle> systemFontFallbacksHandle() const override;
-
-    std::vector<char> systemFont(const std::string& _name, const std::string& _weight,
-                                 const std::string& _face) const override;
-
-    void setRenderCallbackFunction(std::function<void()> callback);
-
-    
-protected:
-
-    void initPlatformFontSetup() const;
-
-    std::string fontPath(const std::string& _name, const std::string& _weight,
-                         const std::string& _face) const;
-
-    UrlClient m_urlClient;
-
-    std::function<void()> m_renderCallbackFunction = nullptr;
-
-    mutable bool m_update = false;
+bool shouldRender();
 
-    mutable std::vector<std::string> m_fallbackFonts;
-    mutable FcConfig* m_fcConfig = nullptr;
+void setRenderCallbackFunction(std::function<void()> callback);
 
-};
+void initUrlRequests(const char* proxyAddress);
+void stopUrlRequests();
 
-} // namespace Tangram
+void setEvasGlAPI(Evas_GL_API* glApi);
similarity index 95%
rename from src/mapzen/tangram/data/properties.h
rename to src/mapzen/tangram/properties.h
index 708655a..baac61e 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
-#include <string>
 #include <vector>
+#include <string>
 
 namespace Tangram {
 
@@ -40,7 +40,7 @@ struct Properties {
 
     std::string getAsString(const std::string& key) const;
 
-    bool getAsString(const std::string& key, std::string& value) const;
+    const bool getAsString(const std::string& key, std::string& value) const;
 
     std::string toJson() const;
 
index 64b731c..b58f4de 100644 (file)
@@ -1,9 +1,7 @@
 #pragma once
 
-#include "data/properties.h"
-#include "util/types.h"
-
-#include <array>
+#include "properties.h"
+#include "types.h"
 #include <functional>
 #include <memory>
 #include <string>
 
 namespace Tangram {
 
-class Platform;
-class TileSource;
-
-enum LabelType {
-    icon,
-    text,
-};
-
-struct FeaturePickResult {
-    FeaturePickResult(std::shared_ptr<Properties> _properties,
-                      std::array<float, 2> _position)
-        : properties(_properties), position(_position) {}
+class DataSource;
 
+struct TouchItem {
     std::shared_ptr<Properties> properties;
-    std::array<float, 2> position;
-};
-
-// Returns a pointer to the selected feature pick result or null, only valid on the callback scope
-using FeaturePickCallback = std::function<void(const FeaturePickResult*)>;
-
-struct LabelPickResult {
-    LabelPickResult(LabelType _type, LngLat _coordinates, FeaturePickResult _touchItem)
-        : type(_type),
-          coordinates(_coordinates),
-          touchItem(_touchItem) {}
-
-    LabelType type;
-    LngLat coordinates;
-    FeaturePickResult touchItem;
+    float position[2];
+    float distance;
 };
 
-// Returns a pointer to the selected label pick result or null, only valid on the callback scope
-using LabelPickCallback = std::function<void(const LabelPickResult*)>;
-
-struct MarkerPickResult {
-    MarkerPickResult(MarkerID _id, LngLat _coordinates, std::array<float, 2> _position)
-        : id(_id), coordinates(_coordinates), position(_position) {}
-
-    MarkerID id;
-    LngLat coordinates;
-    std::array<float, 2> position;
-};
-
-// Returns a pointer to the selected marker pick result or null, only valid on the callback scope
-using MarkerPickCallback = std::function<void(const MarkerPickResult*)>;
-
 struct SceneUpdate {
     std::string path;
     std::string value;
-    SceneUpdate(std::string p, std::string v) : path(p), value(v) {}
-    SceneUpdate() {}
-};
-
-enum Error {
-    scene_update_path_not_found,
-    scene_update_path_yaml_syntax_error,
-    scene_update_value_yaml_syntax_error,
-};
-
-struct SceneUpdateError {
-    SceneUpdate update;
-    Error error;
 };
 
-using SceneUpdateErrorCallback = std::function<void(const SceneUpdateError&)>;
-
-// Function type for a mapReady callback
-using MapReady = std::function<void(void*)>;
-
 enum class EaseType : char {
     linear = 0,
     cubic,
@@ -88,28 +30,20 @@ enum class EaseType : char {
 };
 
 class Map {
-
 public:
 
     // Create an empty map object. To display a map, call either loadScene() or loadSceneAsync().
-    Map(std::shared_ptr<Platform> _platform);
+    Map();
     ~Map();
 
     // Load the scene at the given absolute file path asynchronously
-    // Any pending scene update will be cleared
-    void loadSceneAsync(const char* _scenePath,
-                        bool _useScenePosition = false,
-                        MapReady _onMapReady = nullptr,
-                        void *_onMapReadyUserData = nullptr,
-                        const std::vector<SceneUpdate>& sceneUpdates = {},
-                        SceneUpdateErrorCallback _onSceneUpdateError = nullptr);
+    void loadSceneAsync(const char* _scenePath, bool _useScenePosition = false,
+                        std::function<void(void*)> _platformCallback = {}, void *_cbData = nullptr,
+                        const std::vector<SceneUpdate>& sceneUpdates = {});
 
     // Load the scene at the given absolute file path synchronously
-    // Any pending scene update will be cleared
-    void loadScene(const char* _scenePath,
-                   bool _useScenePosition = false,
-                   const std::vector<SceneUpdate>& sceneUpdates = {},
-                   SceneUpdateErrorCallback _onSceneUpdateError = nullptr);
+    void loadScene(const char* _scenePath, bool _useScenePosition = false,
+                   const std::vector<SceneUpdate>& sceneUpdates = {});
 
     // Request an update to the scene configuration; the path is a series of yaml keys
     // separated by a '.' and the value is a string of yaml to replace the current value
@@ -118,10 +52,7 @@ public:
     void queueSceneUpdate(const std::vector<SceneUpdate>& sceneUpdates);
 
     // Apply all previously requested scene updates
-    void applySceneUpdates(SceneUpdateErrorCallback _onSceneUpdateError = nullptr);
-
-    // Set an MBTiles SQLite database file for a DataSource in the scene.
-    void setMBTiles(const char* _dataSourceName, const char* _mbtilesFilePath);
+    void applySceneUpdates();
 
     // Initialize graphics resources; OpenGL context must be created prior to calling this
     void setupGL();
@@ -143,8 +74,7 @@ public:
     // Gets the viewport width in physical pixels (framebuffer size)
     int getViewportWidth();
 
-    // Set the ratio of hardware pixels to logical pixels (defaults to 1.0);
-    // this operation can be slow, so only perform this when necessary.
+    // Set the ratio of hardware pixels to logical pixels (defaults to 1.0)
     void setPixelScale(float _pixelsPerPoint);
 
     // Gets the pixel scale
@@ -212,15 +142,15 @@ public:
     // point is not visible on the screen, otherwise returns true
     bool lngLatToScreenPosition(double _lng, double _lat, double* _x, double* _y);
 
-    // Add a tile source for adding drawable map data, which will be styled
+    // Add a data source for adding drawable map data, which will be styled
     // according to the scene file using the provided data source name;
-    void addTileSource(std::shared_ptr<TileSource> _source);
+    void addDataSource(std::shared_ptr<DataSource> _source);
 
-    // Remove a tile source from the map; returns true if the source was found
+    // Remove a data source from the map; returns true if the source was found
     // and removed, otherwise returns false.
-    bool removeTileSource(TileSource& _source);
+    bool removeDataSource(DataSource& _source);
 
-    void clearTileSource(TileSource& _source, bool _data, bool _tiles);
+    void clearDataSource(DataSource& _source, bool _data, bool _tiles);
 
     // Add a marker object to the map and return an ID for it; an ID of 0 indicates an invalid marker;
     // the marker will not be drawn until both styling and geometry are set using the functions below.
@@ -233,12 +163,7 @@ public:
     // Set the styling for a marker object; _styling is a string of YAML that specifies a 'draw rule'
     // according to the scene file syntax; returns true if the marker ID was found and successfully
     // updated, otherwise returns false.
-    bool markerSetStylingFromString(MarkerID _marker, const char* _styling);
-
-    // Set an explicit draw group for a marker object; _path is a '.' delimited path to a draw rule
-    // in the current scene. The Marker will be styled using the draw rule specified at this path;
-    // returns true if the marker ID was found and successfully updated, otherwise returns false.
-    bool markerSetStylingFromPath(MarkerID _marker, const char* _path);
+    bool markerSetStyling(MarkerID _marker, const char* _styling);
 
     // Set a bitmap to use as the image for a point marker; _data is a buffer of RGBA pixel data with
     // length of _width * _height; pixels are in row-major order beginning from the bottom-left of the
@@ -308,42 +233,15 @@ public:
     // efficiency, but can cause errors if your application code makes OpenGL calls (false by default)
     void useCachedGlState(bool _use);
 
-    // Set the radius in logical pixels to use when picking features on the map (default is 0.5).
-    void setPickRadius(float _radius);
-
-    // Create a query to select a feature marked as 'interactive'. The query runs on the next frame.
-    // Calls _onFeaturePickCallback once the query has completed, and returns the FeaturePickResult
-    // with its associated properties or null if no feature was found.
-    void pickFeatureAt(float _x, float _y, FeaturePickCallback _onFeaturePickCallback);
-
-    // Create a query to select a label created for a feature marked as 'interactive'. The query runs
-    // on the next frame.
-    // Calls _onLabelPickCallback once the query has completed, and returns the LabelPickResult
-    // with its associated properties or null if no label was found.
-    void pickLabelAt(float _x, float _y, LabelPickCallback _onLabelPickCallback);
-
-    // Create a query to select a marker that is 'interactive'. The query runs on the next frame.
-    // Calls _onLMarkerPickCallback once the query has completed, and returns the MarkerPickResult
-    // with its associated properties or null if no marker was found.
-    void pickMarkerAt(float _x, float _y, MarkerPickCallback _onMarkerPickCallback);
+    const std::vector<TouchItem>& pickFeaturesAt(float _x, float _y);
 
     // Run this task asynchronously to Tangram's main update loop.
     void runAsyncTask(std::function<void()> _task);
 
-    // Send a signal to Tangram that the platform received a memory warning
-    void onMemoryWarning();
-
-    std::shared_ptr<Platform>& getPlatform();
-
 private:
 
     class Impl;
     std::unique_ptr<Impl> impl;
-
-protected:
-
-    std::shared_ptr<Platform> platform;
-
 };
 
 enum DebugFlags {
@@ -355,7 +253,6 @@ enum DebugFlags {
     tangram_infos,      // Various text tangram debug info printed on the screen
     draw_all_labels,    // Draw all labels
     tangram_stats,      // Tangram frame graph stats
-    selection_buffer,   // Render selection framebuffer
 };
 
 // Set debug features on or off using a boolean (see debug.h)
@@ -368,3 +265,4 @@ bool getDebugFlag(DebugFlags _flag);
 void toggleDebugFlag(DebugFlags _flag);
 
 }
+
diff --git a/src/mapzen/tangram/urlClient.h b/src/mapzen/tangram/urlClient.h
deleted file mode 100644 (file)
index 1b48c47..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-#pragma once
-
-#include "platform.h"
-#include <condition_variable>
-#include <functional>
-#include <mutex>
-#include <string>
-#include <thread>
-#include <vector>
-
-namespace Tangram {
-
-class UrlClient {
-
-public:
-
-    struct Options {
-        uint32_t numberOfThreads = 4;
-        uint32_t connectionTimeoutMs = 3000;
-        uint32_t requestTimeoutMs = 30000;
-        std::string proxyAddress;
-    };
-
-    struct Response {
-        std::vector<char> data;
-        bool successful = false;
-        bool canceled = false;
-    };
-
-    UrlClient(Options options);
-    ~UrlClient();
-
-    bool addRequest(const std::string& url, UrlCallback onComplete);
-
-    void cancelRequest(const std::string& url);
-
-private:
-    struct Request {
-        std::string url;
-        UrlCallback callback;
-    };
-
-    struct Task {
-        Request request;
-        Response response;
-    };
-
-    void curlLoop(uint32_t index);
-
-    std::vector<std::thread> m_threads;
-    std::vector<Task> m_tasks;
-    std::vector<Request> m_requests;
-    std::condition_variable m_requestCondition;
-    std::mutex m_requestMutex;
-    Options m_options;
-    bool m_keepRunning = false;
-};
-
-} // namespace Tangram
index bdf9e16..6bef210 100644 (file)
@@ -44,6 +44,19 @@ TangramView::~TangramView()
        // Nothing to do.
 }
 
+void TangramView::initNetworkRequests() {
+       char* proxyAddress = NULL;
+       get_proxy_address(&proxyAddress);
+
+       initUrlRequests(proxyAddress);
+
+       g_free(proxyAddress);
+}
+
+void TangramView::deinitNetworkRequests() {
+       stopUrlRequests();
+}
+
 mapzen_error_e TangramView::create(maps_view_h view, maps_plugin_map_view_ready_cb callback, const char* providerKey)
 {
        if (!view) {
@@ -99,25 +112,16 @@ mapzen_error_e TangramView::create(maps_view_h view, maps_plugin_map_view_ready_
                return error;
        }
 
-       m_readyCb = callback;
-       // TODO: What to do for multiple instances
-       Tangram::setEvasGlAPI(m_api);
-
-       Tangram::UrlClient::Options urlOptions;
-       char* proxyAddress = NULL;
-       get_proxy_address(&proxyAddress);
-       urlOptions.proxyAddress = proxyAddress;
-       g_free(proxyAddress);
-
-       auto platform = std::shared_ptr<Tangram::TizenPlatform>(new Tangram::TizenPlatform(urlOptions));
-       //auto platform = std::make_shared<Tangram::TizenPlatform>();
-
-       platform->setRenderCallbackFunction([=](){
+       setRenderCallbackFunction([=](){
                ecore_main_loop_thread_safe_call_async(&renderingCb, m_image);
        });
 
+       m_readyCb = callback;
+       // TODO: What to do for multiple instances
+       setEvasGlAPI(m_api);
+
        // Set up the tangram map.
-       m_map = new Tangram::Map(platform);
+       m_map = new Tangram::Map();
 
        float scaleFactor = elm_config_scale_get();
        MAPS_LOGD("evas_gl_context_create() set PixelScale %f", scaleFactor);
@@ -221,7 +225,7 @@ mapzen_error_e TangramView::destroy(maps_view_h view)
        }
 
        if (m_map) {
-               static_cast<Tangram::TizenPlatform*>(m_map->getPlatform().get())->setRenderCallbackFunction(nullptr);
+               setRenderCallbackFunction(nullptr);
                removeAllObjects();
                delete m_map;
                m_map = nullptr;
@@ -284,7 +288,7 @@ mapzen_error_e TangramView::render(maps_view_h view, const maps_coordinates_h co
                m_map->setPosition(m_lng, m_lat);
        }
 
-       m_map->getPlatform()->requestRender();
+       requestRender();
 
        return MAPZEN_ERROR_NONE;
 }
@@ -666,7 +670,7 @@ mapzen_error_e TangramView::updateMarker(maps_view_object_h object, Tangram::Mar
                std::snprintf(styleString, sizeof(styleString), styleFormat, int(scaledWidth), int(scaledHeight), anchor.c_str());
 
                MAPS_LOGD("Marker Style String: %s", styleString);
-               m_map->markerSetStylingFromString(tvMarker, styleString);
+               m_map->markerSetStyling(tvMarker, styleString);
 
                error = maps_view_object_marker_get_coordinates(object, &mapsCoord);
                if (error != MAPS_ERROR_NONE) { break; }
@@ -716,7 +720,7 @@ mapzen_error_e TangramView::updatePolyline(maps_view_object_h object, Tangram::M
 
                MAPS_LOGD("Polyline Style String: %s", styleString);
 
-               m_map->markerSetStylingFromString(tvMarker, styleString);
+               m_map->markerSetStyling(tvMarker, styleString);
 
                error = maps_view_object_polyline_foreach_point(object, emplaceCoord, &coords);
                if (error != MAPS_ERROR_NONE) { break; }
@@ -743,7 +747,7 @@ mapzen_error_e TangramView::updatePolygon(maps_view_object_h object, Tangram::Ma
 
                MAPS_LOGD("Polygon Style String: %s", styleString);
 
-               m_map->markerSetStylingFromString(tvMarker, styleString);
+               m_map->markerSetStyling(tvMarker, styleString);
 
                error = maps_view_object_polygon_foreach_point(object, emplaceCoord, &coords);
                if (error != MAPS_ERROR_NONE) { break; }
@@ -868,9 +872,9 @@ void TangramView::setMapType(maps_view_h view)
        if (buildings_enabled != m_buildingsEnabled) {
                m_buildingsEnabled = buildings_enabled;
                if (m_buildingsEnabled) {
-                       sceneUpdates.push_back( {"global.sdk_building_extrude", "true"} );
+                       sceneUpdates.push_back( {"global.building_extrude", "true"} );
                } else {
-                       sceneUpdates.push_back( {"global.sdk_building_extrude", "false"} );
+                       sceneUpdates.push_back( {"global.building_extrude", "false"} );
                }
        }
 
@@ -889,14 +893,14 @@ void TangramView::setMapType(maps_view_h view)
        maps_view_get_language(view, &language);
        if (m_language != language) {
                m_language = language;
-               sceneUpdates.push_back( {"global.ux_language", m_language.substr(0, 2).c_str()} );
+               //sceneUpdates.push_back( {"global.ux_language", m_language.substr(0, 2).c_str()} );
        }
        free(language);
 
        // set provider key for vector tiles
        if (m_providerKey.size() > 0 && !m_isProviderKeySet) {
                MAPS_LOGD("Queueing API key update: %s", m_providerKey.c_str());
-               sceneUpdates.push_back( {"global.sdk_mapzen_api_key", m_providerKey.c_str()} );
+               sceneUpdates.push_back( {"sources.mapzen.url_params.api_key", m_providerKey.c_str()} );
                m_isProviderKeySet = true;
        }
 
index fe7b9c4..ed2da19 100644 (file)
@@ -27,7 +27,7 @@
 #include <mutex>
 
 #include "mapzen_types.h"
-#include "tangram/util/types.h"
+#include "tangram/types.h"
 
 namespace Tangram {
        class Map;
@@ -55,6 +55,9 @@ public:
        mapzen_error_e onViewObject(maps_view_h view, const maps_view_object_h object, maps_view_object_operation_e operation);
        mapzen_error_e captureSnapshot(maps_view_h view, void **data, int *width, int *height, maps_view_colorspace_type_e *cs);
 
+       static void initNetworkRequests();
+       static void deinitNetworkRequests();
+
        int getWidth() { return m_w; }
        int getHeight() { return m_h; }