/* GeoTee runtime styles (published apps + builder canvas) */
.gf-app{--gf-primary:#0f766e;position:relative;width:100%;height:100%;overflow:auto;font-size:13px;color:#2b2f33;line-height:1.35}
.gf-grid{display:grid;grid-template-columns:repeat(12,1fr);gap:8px;padding:8px;min-height:100%;box-sizing:border-box}
.gf-grid.gf-mobile{display:flex;flex-direction:column}
.gf-w{position:relative;background:#fff;border:1px solid #dfe3e7;border-radius:6px;overflow:hidden;display:flex;flex-direction:column;min-width:0;min-height:0;box-shadow:0 1px 2px rgba(0,0,0,.05)}
.gf-w-map,.gf-w-header,.gf-w-image{padding:0}
.gf-w-header{background:none;border:0;box-shadow:none}
.gf-wbody{flex:1;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.gf-map,.gf-mapel{flex:1;min-height:0;width:100%;height:100%}
.gf-title{padding:7px 10px;font-weight:600;border-bottom:1px solid #eceff2;display:flex;align-items:center;gap:8px;flex:none}
.gf-title .gf-count{margin-left:auto;font-weight:400;color:#6b7280;font-size:11.5px}
.gf-title .gf-reset{margin-left:auto;border:0;background:none;cursor:pointer;color:#6b7280;font-size:14px}
.gf-body{flex:1;min-height:0;overflow:auto;padding:8px 10px}
.gf-empty{color:#9aa3ad;font-style:italic;padding:8px 10px;display:block}
.gf-row{display:flex;align-items:center;gap:8px;padding:3px 0;white-space:nowrap;overflow:hidden}
.gf-row span:nth-child(2){overflow:hidden;text-overflow:ellipsis}
.gf-row small{margin-left:auto;color:#9aa3ad}
.gf-row input[type=checkbox]{accent-color:var(--gf-primary);margin:0}
.gf-sw{width:18px;height:12px;border-radius:2px;border:1px solid rgba(0,0,0,.25);flex:none}
.gf-sw.pt{width:12px;height:12px;border-radius:50%;margin:0 3px}
.gf-sw.ln{height:3px;border:0;border-radius:2px}
.gf-sw.ramp{width:60px;height:10px;border:0}
.gf-lgroup{margin-bottom:8px}
.gf-lgroup b{display:block;margin-bottom:2px}
.gf-lgroup .gf-row{padding-left:4px}
/* table */
.gf-tablewrap{padding:0;user-select:text}
.gf-tablewrap table{border-collapse:collapse;font-size:12px;min-width:100%}
.gf-tablewrap th{position:sticky;top:0;background:#f3f5f7;border-bottom:1px solid #dfe3e7;padding:5px 8px;text-align:left;font-weight:600;white-space:nowrap}
.gf-tablewrap td{border-bottom:1px solid #eef1f4;padding:4px 8px;white-space:nowrap;max-width:220px;overflow:hidden;text-overflow:ellipsis}
.gf-tablewrap tr{cursor:pointer}
.gf-tablewrap tr:hover td{background:#f5f9ff}
.gf-tablewrap tr.sel td{background:#d8f1f4}
.gf-pager{display:flex;gap:8px;align-items:center;justify-content:center;padding:5px;font-size:12px;color:#6b7280;position:sticky;bottom:0;background:#fff;border-top:1px solid #eef1f4}
.gf-pager button{border:1px solid #dfe3e7;background:#fff;border-radius:3px;padding:1px 8px;cursor:pointer}
/* filter */
.gf-filter .gf-field{margin-bottom:10px}
.gf-filter label{display:flex;justify-content:space-between;font-size:12px;color:#4b5563;margin-bottom:3px}
.gf-filter label b{color:var(--gf-primary);font-weight:600}
.gf-filter select,.gf-filter input[type=text]{width:100%;border:1px solid #d5dae0;border-radius:4px;padding:4px 6px;font:inherit;font-size:12px;box-sizing:border-box}
.gf-filter select option{padding:2px 4px}
.gf-range{position:relative;height:22px}
.gf-range input[type=range]{position:absolute;left:0;right:0;top:0;width:100%;margin:0;pointer-events:none;-webkit-appearance:none;background:none;height:22px}
.gf-range input[type=range]::-webkit-slider-runnable-track{height:4px;background:#dfe3e7;border-radius:2px}
.gf-range input[type=range]::-webkit-slider-thumb{-webkit-appearance:none;width:14px;height:14px;border-radius:50%;background:var(--gf-primary);border:2px solid #fff;box-shadow:0 0 0 1px rgba(0,0,0,.2);margin-top:-5px;pointer-events:auto;cursor:pointer}
.gf-range input[type=range]:nth-child(2)::-webkit-slider-runnable-track{background:transparent}
/* chart */
.gf-chart{padding:6px;display:flex;flex-direction:column;position:relative}
.gf-chart svg{width:100%;height:100%;flex:1;min-height:0}
.gf-chart [data-k]{cursor:pointer}
.gf-chart .gf-val{font-size:10px;fill:#4b5563}
.gf-chart .gf-lbl{font-size:10.5px;fill:#4b5563}
.gf-pielegend{display:flex;flex-wrap:wrap;gap:4px 10px;font-size:11px;padding:4px 2px;flex:none}
.gf-pielegend i{display:inline-block;width:10px;height:10px;border-radius:2px;margin-right:4px;vertical-align:-1px}
/* search */
.gf-search{position:relative;padding:8px}
.gf-search input{width:100%;box-sizing:border-box;border:1px solid #d5dae0;border-radius:20px;padding:7px 14px;font:inherit;outline:0}
.gf-search input:focus{border-color:var(--gf-primary)}
.gf-results{position:absolute;left:8px;right:8px;top:100%;background:#fff;border:1px solid #d5dae0;border-radius:6px;box-shadow:0 6px 20px rgba(0,0,0,.15);z-index:20;max-height:240px;overflow:auto}
.gf-results:empty{display:none}
.gf-results div{padding:6px 12px;cursor:pointer;border-bottom:1px solid #eef1f4}
.gf-results div:hover{background:#f5f9ff}
/* text / image / header / stat */
.gf-text{padding:12px 14px;overflow:auto;flex:1}
.gf-text h3{margin:0 0 8px;font-size:16px;color:var(--gf-primary)}
.gf-text p{margin:0 0 8px}
.gf-img{margin:0;flex:1;display:flex;flex-direction:column;min-height:0}
.gf-img img{flex:1;min-height:0;width:100%;object-fit:cover}
.gf-img figcaption{padding:5px 10px;font-size:11.5px;color:#6b7280}
.gf-header{display:flex;align-items:center;gap:12px;padding:10px 16px;color:#fff;border-radius:6px;height:100%;box-sizing:border-box}
.gf-header img{height:32px}
.gf-header b{font-size:17px;display:block;line-height:1.2}
.gf-header small{opacity:.85;display:block}
.gf-stat{display:flex;flex-direction:column;justify-content:center;align-items:center;height:100%;text-align:center;padding:8px}
.gf-stat b{font-size:28px;color:var(--gf-primary);line-height:1.1}
.gf-stat span{color:#6b7280;font-size:12px;margin-top:4px}
/* popup */
.maplibregl-popup-content{font:12px "Segoe UI",system-ui,sans-serif;padding:0;border-radius:4px;box-shadow:0 2px 12px rgba(0,0,0,.25);max-width:320px;overflow:hidden}
.gf-ph{color:#fff;padding:6px 10px;font-weight:600}
.gf-pt{border-collapse:collapse;width:100%;max-height:220px;display:block;overflow:auto}
.gf-pt td{padding:3px 10px;border-bottom:1px solid #eef1f4;vertical-align:top}
.gf-pt td:first-child{color:#6b7280;white-space:nowrap}
.maplibregl-popup-close-button{color:#fff;font-size:16px;padding:2px 6px}

/* bookmarks */
.gf-bookmarks{display:flex;flex-direction:column;gap:4px}
.gf-bookmarks button{text-align:left;padding:6px 10px;border:1px solid #dfe3e7;border-radius:4px;background:#fff;cursor:pointer;font:inherit}
.gf-bookmarks button:hover{border-color:var(--gf-primary);background:#f0f7f6}

/* header nav / print */
.gf-header .gf-nav{margin-left:auto;display:flex;gap:4px;flex-wrap:wrap}
.gf-header .gf-nav a{color:#fff;text-decoration:none;padding:5px 12px;border-radius:14px;font-size:12.5px;opacity:.85}
.gf-header .gf-nav a.on,.gf-header .gf-nav a:hover{background:rgba(255,255,255,.22);opacity:1}
.gf-header .gf-print{margin-left:10px;background:rgba(255,255,255,.2);border:0;color:#fff;font-size:16px;border-radius:4px;padding:2px 8px;cursor:pointer}
.gf-header .gf-nav + .gf-print{margin-left:10px}
/* time slider */
.gf-time{padding:8px 12px}
.gf-timerow{display:flex;align-items:center;gap:10px}
.gf-timerow input[type=range]{flex:1;accent-color:var(--gf-primary)}
.gf-timerow b{min-width:80px;text-align:right;color:var(--gf-primary)}
.gf-play{border:1px solid #dfe3e7;background:#fff;border-radius:50%;width:28px;height:28px;cursor:pointer;font-size:11px}
.gf-timelbl{display:flex;justify-content:space-between;font-size:11px;color:#6b7280;margin-top:2px}
/* swipe */
.gf-swipe{position:relative;flex:1;min-height:0;overflow:hidden}
.gf-swipe .gf-mapel{position:absolute;inset:0}
.gf-swipe-bar{position:absolute;top:0;bottom:0;width:4px;background:#fff;box-shadow:0 0 0 1px rgba(0,0,0,.3);cursor:ew-resize;z-index:5;transform:translateX(-2px)}
.gf-swipe-bar i{position:absolute;top:50%;left:50%;width:34px;height:34px;margin:-17px 0 0 -17px;border-radius:50%;background:#fff;box-shadow:0 1px 6px rgba(0,0,0,.4);display:block}
.gf-swipe-bar i::before{content:"◀ ▶";position:absolute;inset:0;display:flex;align-items:center;justify-content:center;font-size:10px;color:#333}
.gf-swipe-lbl{position:absolute;top:8px;background:rgba(255,255,255,.85);padding:2px 8px;border-radius:3px;font-size:11px;z-index:4;pointer-events:none}
.gf-swipe-lbl.l{left:8px}.gf-swipe-lbl.r{right:8px}
@media print{.gf-app{overflow:visible;height:auto}.gf-grid{display:block}.gf-w{break-inside:avoid;margin-bottom:10px;height:auto!important}.gf-w-map{height:520px!important}.gf-print,.gf-nav,.maplibregl-ctrl{display:none!important}}

/* basemap gallery / embed / list */
.gf-bmgal{display:grid;grid-template-columns:repeat(auto-fill,minmax(80px,1fr));gap:6px}
.gf-bmgal button{border:1px solid #dfe3e7;border-radius:6px;background:#fff;padding:4px;font:inherit;font-size:11px;cursor:pointer;display:flex;flex-direction:column;align-items:center;gap:3px}
.gf-bmgal button.on{border-color:var(--gf-primary);background:#f0f7f6}
.gf-bmsw{width:100%;height:36px;border-radius:4px;border:1px solid #dfe3e7}
.bm-light{background:linear-gradient(135deg,#ececec,#d8d8d8)}.bm-bright{background:linear-gradient(135deg,#f6f1e5,#bfe0f3 60%,#cde9c2)}.bm-liberty{background:linear-gradient(135deg,#f3efe6,#dbe8d4 60%,#a9d4ee)}.bm-lightraster{background:linear-gradient(135deg,#e6e6e6,#cfcfcf)}.bm-streets{background:linear-gradient(135deg,#f2ecdc,#cfe0c9 60%,#aad3df)}.bm-humanitarian{background:linear-gradient(135deg,#fbf3e6,#d9ead3)}.bm-topo{background:linear-gradient(135deg,#d6e8c6,#b7a887)}.bm-imagery{background:linear-gradient(135deg,#2f4f2f,#5a6b3a 60%,#1e3a5f)}
.gf-iframe{flex:1;width:100%;border:0;min-height:0}
.gf-list{padding:6px}
.gf-card{display:flex;gap:10px;align-items:center;padding:7px 8px;border:1px solid #eceff2;border-radius:6px;margin-bottom:5px;cursor:pointer;background:#fff}
.gf-card:hover{border-color:var(--gf-primary)}
.gf-card.sel{background:#e3f3f1;border-color:var(--gf-primary)}
.gf-card img{width:48px;height:48px;object-fit:cover;border-radius:4px;flex:none}
.gf-card b{display:block;font-size:13px}
.gf-card small{color:#6b7280}
.gf-place{margin-right:6px}
