/* City navigation shell. All coordinates share one relative map; no inline styles/CSP exception. */
.city-shell{--rail:58px;min-height:100dvh;background:#0c1422}.city-header{display:grid;grid-template-columns:minmax(210px,1fr) minmax(450px,1.8fr) auto;align-items:center;gap:14px;padding:12px 18px 12px calc(var(--rail) + 14px);border-bottom:1px solid #364454;background:#111c2a;position:relative;z-index:3}.city-header .brand{font-size:16px;letter-spacing:.025em}.city-header .eyebrow{font-size:9px;letter-spacing:.08em}.city-header .logo{height:36px;width:36px;font-size:21px}.city-header .stats{grid-template-columns:repeat(5,minmax(0,1fr));gap:6px;margin:0}.city-header .stat{padding:8px;background:#192637;box-shadow:none;border:1px solid #364454}.city-header .stat strong{font-size:15px;overflow-wrap:anywhere}.city-header .stat .caption{font-size:10px;letter-spacing:0}.city-user{display:flex;align-items:center;gap:6px;flex-wrap:wrap;max-width:260px}.city-user>span{overflow-wrap:anywhere;max-width:160px;font-size:13px}.city-rail{position:fixed;inset:0 auto 0 0;width:var(--rail);padding:12px 6px;background:#101824;border-right:1px solid #364454;z-index:6;display:flex;flex-direction:column;gap:10px}.city-nav-button,.city-more>summary{position:relative;display:grid;place-items:center;min-width:44px;min-height:44px;border:1px solid #42536a;background:#1b2a3e;color:#e7f6ff;border-radius:10px;cursor:pointer;font-size:21px;list-style:none}.city-nav-button[aria-current]{border-color:var(--teal);background:#244446}.city-nav-button:hover,.city-more>summary:hover{background:#304860}.city-more>summary::-webkit-details-marker{display:none}.city-more-menu{position:absolute;left:calc(var(--rail) + 6px);top:12px;max-height:calc(100dvh - 24px);overflow:auto;width:min(260px,calc(100vw - 76px));display:grid;padding:10px;gap:5px;background:#162638;border:1px solid #50677e;border-radius:12px;box-shadow:0 10px 40px #0009}.city-more-menu button{background:#203249;color:#edf6ff;border:0;border-radius:6px;text-align:left;padding:12px;cursor:pointer}.city-marker[hidden]{display:none}.city-marker{position:absolute;right:2px;top:2px;width:8px;height:8px;border-radius:50%;background:var(--gold)}.city-main{margin-left:var(--rail);padding:14px;min-width:0}.city-pending:empty{display:none}.city-stage{max-width:1700px;margin:auto}.city-map{position:relative;isolation:isolate;width:100%;height:clamp(520px,calc(100dvh - 125px),1000px);overflow:hidden;border:1px solid #3d5b6b;border-radius:18px;background:repeating-linear-gradient(0deg,transparent 0 60px,#20414344 61px 62px),repeating-linear-gradient(90deg,transparent 0 80px,#20414344 81px 82px),linear-gradient(135deg,#182b39,#123e42);box-shadow:inset 0 0 120px #050b1d88}.city-map-title{position:absolute;top:3%;left:4%;right:18%;z-index:1}.city-map-title h1{margin:0;font-size:clamp(20px,2.2vw,34px);letter-spacing:.13em}.city-map-title h1 span{color:var(--teal);font-size:.55em;white-space:nowrap}.city-map-title p{font-size:13px;color:#bdd3df;margin:5px 0}.city-water{position:absolute;right:0;top:0;width:14%;height:100%;background:repeating-linear-gradient(170deg,#13485599 0 30px,#20647377 31px 32px);border-left:4px solid #599b9e;color:#83b9c5;writing-mode:vertical-rl;text-align:center;padding:15px;letter-spacing:.2em;font-size:12px}.city-road{position:absolute;background:#314351;border:2px solid #59707c;z-index:-1}.city-road-horizontal{left:0;right:14%;height:8%;top:49%}.city-road-vertical{top:14%;bottom:0;left:42%;width:7%}.city-building{position:absolute;width:19%;height:23%;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:6px;background:transparent;border:0;color:#f5f7ff;cursor:pointer;text-align:center;padding:4px;min-width:0}.city-building-shape{display:grid;place-items:center;width:65%;height:60%;font-size:clamp(22px,4vw,50px);background:linear-gradient(135deg,#49657c,#203c55);border:2px solid #8cafbc;border-bottom:7px solid #132537;border-radius:6px;box-shadow:8px 8px 0 #07192966;color:#9cf8dd}.tower .city-building-shape{height:72%;width:50%;border-color:#a1cddd}.bank .city-building-shape{color:#f6d294}.market .city-building-shape{color:#ffadd8}.city-building-name{max-width:100%;padding:3px 7px;border-radius:5px;background:#0b1725e8;font-size:clamp(11px,1.15vw,15px);line-height:1.3;overflow-wrap:anywhere}.city-building:hover .city-building-shape{border-color:#ffb8e5;background:#3f5975}.city-building:focus-visible{outline:3px solid var(--teal);outline-offset:2px;border-radius:8px}.city-vacant{cursor:default;opacity:.6}.city-vacant .city-building-shape{border-style:dashed;background:#243c45}.tower{left:5%;top:18%}.bank{left:30%;top:18%}.market{left:59%;top:18%}.club-a{left:3%;top:59%}.club-b{left:25%;top:68%}.club-c{left:53%;top:63%}.club-d{left:62%;top:39%}.club-e{left:21%;top:40%}.city-window{background:#101b2a;border:1px solid #486177;border-radius:14px;padding:18px;min-width:0;overflow:auto;max-height:calc(100dvh - 130px);scrollbar-gutter:stable}.city-window-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;border-bottom:1px solid #364454;padding-bottom:12px;margin-bottom:18px}.city-window-heading h1{font-size:22px;margin:0;overflow-wrap:anywhere}.city-window-heading button{flex-shrink:0}.city-company-tabs{display:flex;flex-wrap:wrap;gap:10px;margin-bottom:18px}.city-window .inline-form label{min-width:min(180px,100%)}.city-window .club-navigation>label{min-width:min(220px,100%)}.city-window .table-wrap{max-width:100%}.city-window .panel{min-width:0}.city-shell button:focus-visible,.city-shell summary:focus-visible{outline:2px solid var(--teal);outline-offset:3px}
@media(max-width:1200px){.city-header{grid-template-columns:1fr auto}.city-header .stats{grid-column:1/-1;grid-row:2}.city-window{max-height:calc(100dvh - 195px)}.city-map{height:clamp(520px,calc(100dvh - 195px),900px)}}
@media(max-width:600px){.city-shell{--rail:50px}.city-rail{padding:8px 3px;gap:7px}.city-header{padding:10px 10px 10px calc(var(--rail) + 10px);gap:10px}.city-header .identity{gap:7px}.city-header .logo{display:none}.city-header .brand{font-size:13px}.city-header .eyebrow{font-size:8px}.city-user{justify-content:flex-end;max-width:135px}.city-user>span{max-width:130px;font-size:11px}.city-user .button{padding:6px;font-size:11px}.city-header .stats{grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}.city-header .stat{padding:5px}.city-header .stat strong{font-size:12px}.city-header .stat .caption{font-size:9px}.city-main{padding:8px}.city-map{height:650px;border-radius:10px}.city-map-title{right:4%;left:5%}.city-map-title h1{font-size:18px}.city-map-title p{font-size:11px}.city-water{width:7%;padding:4px;font-size:9px}.city-building{width:28%;height:19%}.city-building-shape{width:75%;height:56%;font-size:28px;box-shadow:4px 4px 0 #07192966}.tower{left:3%;top:16%}.bank{left:33%;top:16%}.market{left:63%;top:16%}.club-a{left:3%;top:42%}.club-b{left:33%;top:42%}.club-c{left:63%;top:42%}.club-d{left:14%;top:72%}.club-e{left:50%;top:72%}.city-road-horizontal{top:36%;right:7%;height:5%}.city-road-vertical{left:45%;top:13%;width:5%}.city-window{padding:10px;max-height:none;min-height:60dvh}.city-window-heading h1{font-size:17px}.city-window .panel{padding:12px}.city-window .grid{grid-template-columns:minmax(0,1fr)}.city-window .club-bars{grid-template-columns:minmax(0,1fr)}.city-window .table{white-space:normal}.city-window .club-stats{grid-template-columns:repeat(2,minmax(0,1fr))}.city-window .inline-form{min-width:0}.city-window input,.city-window select{max-width:100%}.city-window .button{white-space:normal}}
@media(max-height:430px){.city-rail{gap:3px;padding-top:4px}.city-nav-button,.city-more>summary{min-height:36px}.city-window{max-height:none}}
@media(min-width:601px){.city-building{height:21%}.tower,.bank,.market{top:17%}.club-a{left:5%;top:44%}.club-b{left:32%;top:44%}.club-c{left:60%;top:44%}.club-d{left:17%;top:73%}.club-e{left:46%;top:73%}}
.city-building-name{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;max-height:4.5em}

/* Overlay Testfix1: one viewport, an automatic header row and independent UI layers. */
.city-shell{position:fixed;inset:0;min-height:0;height:100dvh;display:grid;grid-template-columns:var(--rail) minmax(0,1fr);grid-template-rows:auto minmax(0,1fr);isolation:isolate;background:transparent;overflow:hidden}
.city-map{display:contents;background:none;border:0;border-radius:0;box-shadow:none;padding:0}
.city-map::before{content:"";position:fixed;inset:0;z-index:-2;pointer-events:none;background:var(--city-scene-image,linear-gradient(135deg,#182b39,#123e42));background-size:cover;background-position:center}
.city-elements{grid-column:2;grid-row:2;position:relative;min-height:0;min-width:0;z-index:0}
.city-map[inert] .city-elements{pointer-events:none}
.city-road{z-index:-1}.city-building:disabled{cursor:default;opacity:1}.city-building:disabled:hover .city-building-shape{background:linear-gradient(135deg,#49657c,#203c55);border-color:#8cafbc}
.city-map-title{top:1%;pointer-events:none}.city-map-title h1{font-size:clamp(16px,2vw,28px)}
.city-header{grid-column:1/-1;grid-row:1;z-index:3;background:transparent;border:0;padding:12px 18px;min-width:0}
.city-header .identity,.city-user{filter:drop-shadow(0 2px 3px #000)}
.city-header .brand,.city-header .eyebrow,.city-user>span{text-shadow:0 1px 4px #000}
.city-user .button{background:#152536d9}
.city-rail{grid-column:1;grid-row:2;position:relative;inset:auto;width:auto;min-height:0;z-index:4;background:transparent;border:0;overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}
.city-more-menu{position:fixed;top:180px;bottom:12px;left:calc(var(--rail) + 6px);max-height:calc(100dvh - 192px);height:max-content}
.city-main{grid-column:2;grid-row:2;z-index:2;position:relative;margin:0;padding:12px 24px 18px 12px;min-height:0;display:flex;flex-direction:column;gap:8px;pointer-events:none;overflow:hidden}
.city-pending{pointer-events:auto;flex:none;max-height:35%;overflow:auto}.city-stage{width:100%;max-width:1500px;min-height:0;flex:1;display:flex;flex-direction:column;pointer-events:none}
.city-window{pointer-events:auto;min-height:0;max-height:100%;overflow:auto;overscroll-behavior:contain;flex:1;background:#101b2af5;box-shadow:0 10px 40px #0007}
@media(max-width:1200px){.city-header{grid-template-columns:1fr auto}.city-window{max-height:100%}}
@media(max-width:600px){.city-header{padding:8px;gap:6px}.city-main{padding:6px 8px 8px 4px}.city-window{min-height:0;max-height:100%;padding:10px}.city-map-title p{display:none}.city-building{height:22%}.city-building-shape{min-height:20px}.city-building-name{-webkit-line-clamp:2;max-height:3.2em;font-size:11px}.tower,.bank,.market{top:12%}.club-a,.club-b,.club-c{top:40%}.club-d,.club-e{top:70%}}
@media(max-height:500px){.city-map-title{display:none}.city-building-shape{font-size:20px}.city-building-name{font-size:10px;-webkit-line-clamp:1;max-height:1.9em}.city-rail{padding-top:4px;gap:4px}.city-nav-button,.city-more>summary{min-height:36px}.city-more-menu{top:120px;max-height:calc(100dvh - 132px)}.city-window{max-height:100%}}
body:has(.city-shell){height:100dvh;min-height:0;overflow:hidden}

/* Miami artwork: one 3:2 plane, identical transform for image and every hotspot. */
.city-map::before{background:#102f42}
.city-elements{position:fixed;inset:auto;left:50%;top:50%;width:max(100vw,150dvh);height:max(100dvh,66.666667vw);transform:translate(-50%,-50%);background:url('images/miami-night.png') center/100% 100% no-repeat;grid-column:auto;grid-row:auto}
.city-elements .city-building{position:absolute;display:flex;justify-content:flex-end;align-items:center;padding:0 3px 4px;gap:0;border:0;border-radius:14px;background:transparent;opacity:1;height:auto}
.city-elements .city-building-shape{display:none}
.city-elements .city-building-name{display:block;max-width:100%;max-height:none;overflow:visible;padding:5px 9px;font-size:clamp(11px,1vw,15px);line-height:1.3;background:#101d2be8;border:1px solid #97d8e55e;border-radius:7px;box-shadow:0 3px 12px #0007;color:#fff;text-shadow:none}
.city-elements .city-building:hover:not(:disabled){box-shadow:inset 0 0 25px #86ffe75c;outline:1px solid #c3fff18c}
.city-elements .city-building:disabled{pointer-events:none}
.city-elements .city-vacant .city-building-name{background:#29323de6;color:#d7e0e5;font-size:11px}
.city-elements .tower{left:12%;top:4%;width:19%;height:36%}
.city-elements .bank{left:40%;top:17%;width:19%;height:24%}
.city-elements .market{left:65%;top:21%;width:23%;height:22%}
.city-elements .club-a{left:9%;top:45%;width:21%;height:20%}
.city-elements .club-b{left:39%;top:45%;width:22%;height:21%}
.city-elements .club-c{left:69%;top:45%;width:23%;height:21%}
.city-elements .club-d{left:24%;top:69%;width:22%;height:24%}
.city-elements .club-e{left:58%;top:69%;width:23%;height:24%}
.city-status{display:inline-block;margin:3px 2px 0;padding:2px 6px;border-radius:4px;font-size:11px;white-space:normal}.city-status-open{color:#a4ffdd;background:#125544}.city-status-closed{color:#e1e5ed;background:#3b4659}.city-status-work{color:#ffe1a4;background:#685024}.city-building-name>.city-status:first-of-type{margin-left:6px}
.city-header .identity{background:#0b1725a8;border-radius:10px;padding:7px 10px}.city-header .stat{background:#111d2cdb;backdrop-filter:blur(8px)}.city-user{background:#0b1725b8;border-radius:9px;padding:5px}.city-nav-button,.city-more>summary{background:#132438d9;border-color:#a0c8d74d;box-shadow:0 3px 12px #0005;backdrop-filter:blur(8px)}.city-window{background:#101b2aeb}
@media(max-width:600px){.city-elements .city-building-name{font-size:11px}.city-header .identity{padding:5px}.city-window{background:#101b2af2}}

/* City Visual Rework Test1: contain the shared artwork/hit plane below the header.
   This invisible grid area is not a window. No building is cropped by cover scaling. */
.city-map{display:block;grid-column:2;grid-row:2;position:relative;isolation:auto;width:100%;height:100%;min-width:0;min-height:0;container-type:size;overflow:visible;background:none;border:0;border-radius:0;box-shadow:none;padding:0}
.city-map::before{background:radial-gradient(ellipse at 55% 55%,#244058,#132939 75%,#102432)}
.city-elements{position:absolute;left:50%;top:50%;width:min(98cqw,147cqh);height:min(98cqh,65.333333cqw);transform:translate(-50%,-50%);background:url('images/miami-cartoon-test1.png') center/100% 100% no-repeat}
.city-elements .city-building{--place-accent:#80eff0;padding:0 2px 2px;cursor:pointer;border-radius:12px;transition:filter .15s ease}
.city-elements .tower{--place-accent:#99c7ff}
.city-elements .bank{--place-accent:#ffd478}
.city-elements .market{--place-accent:#83f0c5}
.city-elements .city-building-name{box-sizing:border-box;position:relative;display:block;max-width:100%;padding:7px 10px;border:2px solid var(--place-accent);border-radius:10px;background:linear-gradient(#304a70,#192d4b);box-shadow:0 4px 0 #091b30,0 7px 12px #07142799;color:#fff;font-size:clamp(10px,1.1vw,16px);font-weight:800;line-height:1.18;text-shadow:0 1px 2px #000;overflow-wrap:normal;hyphens:auto}
.city-elements .city-building-name::before{content:"";position:absolute;left:calc(50% - 5px);top:-7px;width:8px;height:8px;background:var(--place-accent);transform:rotate(45deg);border-radius:1px}
.city-elements .city-vacant{--place-accent:#ffc976;cursor:pointer}
.city-elements .city-vacant .city-building-name{background:linear-gradient(#58425b,#302c48);color:#fff0cf;font-size:clamp(10px,1vw,14px)}
.city-elements .city-building:hover:not(:disabled){filter:brightness(1.15);box-shadow:none;outline:0}
.city-elements .city-building:hover:not(:disabled) .city-building-name{background:#34557a;box-shadow:0 4px 0 #091b30,0 0 18px #8be4f077}
.city-elements .city-building:focus-visible{outline:3px solid #fff1ad;outline-offset:2px}
.city-elements .city-status{font-size:clamp(9px,.85vw,12px);font-weight:600;padding:2px 4px;margin:4px 1px 0;text-shadow:none}
.city-elements .city-building-name>.city-status:first-of-type{margin-left:3px}
@media(max-width:600px){.city-elements .city-building-name{padding:4px 3px;border-radius:6px;font-size:10px;line-height:1.15}.city-elements .city-vacant .city-building-name{font-size:10px}.city-elements .city-status{padding:1px 2px;margin-top:2px;font-size:9px}}
@media(prefers-reduced-motion:reduce){.city-elements .city-building{transition:none}}

/* District Test3: full-screen art and matching landmark hit areas. No navigation changes. */
.city-shell::before{content:"";position:fixed;inset:0;z-index:-2;pointer-events:none;background:#14202c url('images/miami-district-test3.png') center/cover no-repeat}
.city-map{container-type:normal}
.city-map::before{display:none}
.city-elements{position:fixed;inset:0;width:100vw;height:100dvh;transform:none;background:url('images/miami-district-test3.png') center/100% 100% no-repeat}
.city-elements .tower{left:12%;top:9%;width:18%;height:24%}
.city-elements .bank{left:39%;top:10%;width:20%;height:25%}
.city-elements .market{left:68%;top:12%;width:24%;height:24%}
.city-elements .club-a{left:7%;top:36%;width:22%;height:26%}
.city-elements .club-b{left:40%;top:41%;width:18%;height:23%}
.city-elements .club-c{left:68%;top:36%;width:25%;height:29%}
.city-elements .club-d{left:23%;top:62%;width:25%;height:32%}
.city-elements .club-e{left:55%;top:61%;width:29%;height:34%}
/* Narrow and short displays: keep the entire clickable district below navigation.
   The same artwork fills the viewport behind it; no off-screen properties. */
@media(max-aspect-ratio:1/1),(max-height:500px){
 .city-shell::before{filter:blur(12px) brightness(.55);transform:scale(1.06)}
 .city-map{container-type:size}
 .city-elements{position:absolute;inset:auto;left:50%;top:50%;width:min(98cqw,174.129649cqh);height:min(98cqh,55.154306cqw);transform:translate(-50%,-50%)}
}

/* Legible at navigation size: warm ivory outlines, restrained brass accents. */
.city-icon{display:inline-block;width:1.15em;height:1.15em;vertical-align:-.2em;color:#f2e8d9;pointer-events:none;flex-shrink:0}
.city-icon-accent{stroke:#dfb779}
.city-nav-button[aria-current] .city-icon{color:var(--teal)}
.city-more-menu .city-icon{width:22px;height:22px;vertical-align:middle;margin-right:8px}

/* Navigation Size Test1: enlarge only the six primary rail controls. */
.city-shell{--rail:72px}
.city-rail>.city-nav-button,.city-rail>.city-more>summary{box-sizing:border-box;width:55px;height:55px;min-width:55px;min-height:55px;padding:0;flex-shrink:0}
.city-rail>.city-nav-button>span:first-child{display:grid;place-items:center;line-height:0}
.city-rail>.city-nav-button .city-icon,.city-rail>.city-more>summary>.city-icon{width:32px;height:32px;vertical-align:0}
@media(max-width:600px){.city-shell{--rail:64px}}

/* Property close-ups reuse the unchanged district artwork; no new image assets. */
.city-property-image{width:100%;max-width:650px;margin:0 auto 18px;border-radius:12px;background-image:url('images/miami-district-test3.png');background-repeat:no-repeat;background-color:#14202c}
.city-property-underground{aspect-ratio:36784/24466;background-size:303.030303% 256.410256%;background-position:2.238806% 45.081967%}
.city-property-city{aspect-ratio:30096/21643;background-size:370.370370% 289.855072%;background-position:48.630137% 53.816794%}
.city-property-warehouse{aspect-ratio:41800/27289;background-size:266.666667% 229.885057%;background-position:98.800000% 47.345133%}
.city-property-elite{aspect-ratio:41800/30112;background-size:266.666667% 208.333333%;background-position:26.800000% 96.153846%}
.city-property-mega{aspect-ratio:48488/31994;background-size:229.885057% 196.078431%;background-position:84.513274% 98.979592%}

/* Map Visual Testfix1: lift plaques, keeping the artwork and building rectangles fixed.
   Plaques sit above neighbouring hit rectangles. Hover must not create a stacking
   context on the entire building, otherwise a neighbour can cover its plaque. */
.city-elements .city-building-name{transform:translateY(clamp(-38px,-3.5vh,-8px));z-index:2}
.city-elements .city-building:hover:not(:disabled){filter:none}
.city-elements .city-building:hover:not(:disabled) .city-building-name{filter:brightness(1.15)}
@media(max-aspect-ratio:1/1),(max-height:500px){
 .city-elements .city-building-name{transform:translateY(-8px)}
}

/* Existing venue windows use the same district close-up presentation. */
.city-property-tower{aspect-ratio:40128/30112;background-size:333.333333% 250.000000%;background-position:8.571429% 0.000000%}
.city-property-bank{aspect-ratio:46816/30112;background-size:357.142857% 312.500000%;background-position:48.611111% 4.411765%}
.city-property-market{aspect-ratio:53504/30112;background-size:312.500000% 312.500000%;background-position:94.117647% 5.882353%}

/* One consistent staff planning grid, including leadership and optional roles. */
.club-staff-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));grid-auto-rows:1fr;align-items:stretch}
.club-staff-cards>.club-staff-card{box-sizing:border-box;height:100%;min-width:0;display:flex;flex-direction:column}
.club-staff-card .management-meter{width:100%;box-sizing:border-box}
