:root{
  --bg:#24231f;
  --bg-soft:#2c2a26;
  --panel:#302e29;
  --panel-hover:#37342f;
  --line:#514d45;
  --line-soft:#403d37;
  --text:#e5dcc8;
  --muted:#aea593;
  --cream:#eadfc8;
  --red:#b44d38;
  --red-soft:#d27b5d;
  --blu:#4f7484;
  --blu-soft:#81a3b0;
  --orange:#cf7548;
  --paper:#d1c3a5;
  --ink:#312d27;
}

*{box-sizing:border-box}
html{scroll-behavior:smooth}

body{
  margin:0;
  min-height:100vh;
  color:var(--text);
  background:var(--bg);
  font-family:Arial,Helvetica,sans-serif;
}

button,input{font:inherit}
button{color:inherit}

.site-header{
  position:sticky;
  top:0;
  z-index:20;
  background:#1f1e1b;
  border-bottom:1px solid #49453e;
}

.header-inner{
  width:min(1160px,94%);
  min-height:66px;
  margin:0 auto;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:22px;
}

.team-line{
  height:3px;
  display:grid;
  grid-template-columns:1fr 1fr;
}

.red-line{background:var(--red)}
.blu-line{background:var(--blu)}

.brand{
  padding:0;
  border:0;
  background:transparent;
  text-align:left;
  cursor:pointer;
}

.brand-title{
  display:block;
  color:var(--cream);
  font-family:Impact,Haettenschweiler,"Arial Narrow Bold",sans-serif;
  font-size:1.45rem;
  font-weight:400;
  letter-spacing:.7px;
}

.brand-note{
  display:block;
  margin-top:1px;
  color:#8f8778;
  font-size:.62rem;
  letter-spacing:.55px;
  text-transform:uppercase;
}

nav{
  display:flex;
  gap:2px;
  align-items:center;
  flex-wrap:wrap;
}

.nav-btn{
  padding:9px 10px;
  border:0;
  border-bottom:2px solid transparent;
  background:transparent;
  color:#aaa18f;
  cursor:pointer;
  font-size:.73rem;
  font-weight:700;
  text-transform:uppercase;
}

.nav-btn:hover{color:#ded5c3}

.nav-btn.active{
  color:#fff0d4;
  border-bottom-color:var(--orange);
}

main{
  width:min(1120px,92%);
  margin:0 auto;
}

.view{
  display:none;
  padding:50px 0 68px;
}

.view.active{display:block}

.eyebrow{
  margin:0 0 6px;
  color:var(--orange);
  font-size:.66rem;
  font-weight:800;
  letter-spacing:1.3px;
  text-transform:uppercase;
}

/* Home */

.hero{
  display:grid;
  grid-template-columns:minmax(0,1.35fr) minmax(270px,.65fr);
  gap:22px;
  padding:24px 0 22px;
}

.hero-copy{
  display:flex;
  flex-direction:column;
  justify-content:center;
  padding:14px 0;
}

.hero h1{
  margin:0;
  color:var(--cream);
  font-family:Impact,Haettenschweiler,"Arial Narrow Bold",sans-serif;
  font-size:clamp(3rem,7vw,5.4rem);
  font-weight:400;
  line-height:.95;
  letter-spacing:.45px;
}

.hero-text{
  max-width:680px;
  margin:16px 0 0;
  color:var(--muted);
  line-height:1.6;
}

.hero-actions{
  display:flex;
  gap:7px;
  flex-wrap:wrap;
  margin-top:20px;
}

.button,
.connect-button{
  display:inline-flex;
  min-height:39px;
  align-items:center;
  justify-content:center;
  padding:8px 13px;
  border:1px solid var(--line);
  border-radius:3px;
  color:#ddd4c1;
  background:var(--panel);
  cursor:pointer;
  font-size:.75rem;
  font-weight:800;
  text-decoration:none;
  text-transform:uppercase;
}

.button:hover,
.connect-button:hover{
  background:var(--panel-hover);
}

.button.primary{
  color:#fff1d7;
  background:#8f3f31;
  border-color:#a74b38;
}

.button.primary:hover{background:#a84834}

.server-card{
  padding:16px;
  background:#2b2925;
  border:1px solid var(--line);
  border-top:3px solid var(--blu);
}

.server-title{
  margin-bottom:8px;
  color:var(--cream);
  font-size:.78rem;
  font-weight:800;
  text-transform:uppercase;
}

.server-row{
  display:grid;
  grid-template-columns:70px 1fr;
  gap:12px;
  padding:9px 0;
  border-top:1px solid var(--line-soft);
}

.server-row span{
  color:#8f8779;
  font-size:.7rem;
  text-transform:uppercase;
}

.server-row strong,
.server-row code{
  color:#d5cbb8;
  text-align:right;
}

.server-row code{font-size:.78rem}

.connect-button{
  width:100%;
  margin-top:10px;
  border-left:3px solid var(--blu);
}

.server-card small{
  display:block;
  margin-top:9px;
  color:#817a6e;
  font-size:.67rem;
}

.home-links{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:8px;
}

.home-card{
  min-height:112px;
  padding:14px;
  border:1px solid var(--line);
  border-left:3px solid #676159;
  border-radius:3px;
  background:var(--panel);
  text-align:left;
  cursor:pointer;
}

.home-card.red-card{border-left-color:var(--red)}
.home-card.blu-card{border-left-color:var(--blu)}
.home-card:hover{background:var(--panel-hover)}

.home-card strong{
  display:block;
  margin-bottom:7px;
  color:var(--cream);
  font-size:1rem;
}

.home-card span{
  color:var(--muted);
  font-size:.8rem;
  line-height:1.4;
}

.community-note{
  margin-top:14px;
  padding:10px 12px;
  color:#9e9585;
  background:#211f1c;
  border:1px dashed #48443d;
  font-size:.72rem;
}

.community-note strong{color:#c9bdab}

/* Shared section layout */

.section-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:24px;
  margin-bottom:20px;
  padding-bottom:14px;
  border-bottom:1px solid var(--line);
}

.section-head h2{
  margin:0;
  color:var(--cream);
  font-family:Impact,Haettenschweiler,"Arial Narrow Bold",sans-serif;
  font-size:clamp(2.2rem,4.8vw,3.4rem);
  font-weight:400;
  line-height:1;
}

.section-head p:not(.eyebrow){
  max-width:650px;
  margin:8px 0 0;
  color:var(--muted);
  line-height:1.45;
}

.search{
  width:min(390px,100%);
  min-height:40px;
  padding:9px 11px;
  color:var(--text);
  background:#1e1d1a;
  border:1px solid var(--line);
  border-radius:3px;
  outline:none;
}

.search::placeholder{color:#7f786d}
.search:focus{border-color:var(--orange)}

.grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(235px,1fr));
  gap:9px;
}

.item-card{
  padding:14px;
  background:var(--panel);
  border:1px solid var(--line);
  border-top:2px solid #625d55;
  border-radius:3px;
}

.item-card:nth-child(3n+1){border-top-color:var(--red)}
.item-card:nth-child(3n+2){border-top-color:var(--blu)}

.item-card h3{
  margin:0 0 5px;
  color:var(--cream);
  font-size:1.04rem;
}

.item-card p{
  margin:5px 0;
  color:var(--muted);
  font-size:.82rem;
  line-height:1.42;
}

.item-img{
  width:100%;
  height:130px;
  object-fit:contain;
  margin-bottom:11px;
  background:#22211e;
  border:1px solid #46423c;
}

.tag{
  display:inline-block;
  margin:7px 4px 0 0;
  padding:3px 6px;
  color:#cfc5b3;
  background:#22211e;
  border:1px solid #4d4942;
  border-radius:2px;
  font-size:.62rem;
  font-weight:800;
  text-transform:uppercase;
}

/* Bosses */

.boss-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(220px,1fr));
  gap:7px;
  align-items:start;
}

.boss-name-item{
  min-height:42px;
  display:flex;
  align-items:center;
  padding:9px 11px;
  color:var(--cream);
  background:var(--panel);
  border:1px solid var(--line);
  border-left:3px solid #625d55;
  border-radius:3px;
  font-size:.82rem;
  font-weight:700;
}

.boss-name-item:nth-child(odd){
  border-left-color:var(--red);
}

.boss-name-item:nth-child(even){
  border-left-color:var(--blu);
}

.boss-name-item:hover{
  background:var(--panel-hover);
}

.boss-list-meta{
  display:flex;
  align-items:baseline;
  gap:6px;
  margin:-8px 0 12px;
  color:#827a6e;
  font-size:.68rem;
}

.boss-list-meta strong{
  color:var(--cream);
  font-size:.9rem;
}

@media(max-width:700px){
  .boss-grid{
    grid-template-columns:1fr;
  }
}

/* Commands */

.tip{
  margin-bottom:10px;
  padding:10px 12px;
  color:#352f28;
  background:var(--paper);
  border-left:3px solid var(--orange);
  font-size:.78rem;
}

.tip code{font-weight:800}

.command-list{
  display:grid;
  gap:8px;
}

.command-card{
  display:grid;
  grid-template-columns:120px 1fr auto;
  gap:14px;
  align-items:center;
  padding:12px 13px;
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:3px;
}

.command-card code{
  color:#eadfc8;
  font-size:.8rem;
}

.command-card h3{
  margin:0 0 3px;
  color:var(--cream);
  font-size:.88rem;
}

.command-card p{
  margin:0;
  color:var(--muted);
  font-size:.78rem;
  line-height:1.4;
}

.command-meta{
  color:#cf7a52;
  font-size:.61rem;
  font-weight:800;
  text-transform:uppercase;
}

/* Changelog */

.filters{
  display:flex;
  flex-wrap:wrap;
  gap:5px;
}

.filter-btn{
  padding:6px 8px;
  color:#a99f8e;
  background:#211f1c;
  border:1px solid var(--line);
  border-radius:3px;
  cursor:pointer;
  font-size:.64rem;
  font-weight:800;
  text-transform:uppercase;
}

.filter-btn:hover,
.filter-btn.active{
  color:#f0dfc4;
  border-color:#9a5139;
  background:#402b24;
}

.change-list{
  display:grid;
  gap:8px;
}

.change-card{
  padding:13px 14px;
  background:var(--panel);
  border:1px solid var(--line);
  border-left:3px solid #625d55;
  border-radius:3px;
}

.change-card[data-type="boss"]{border-left-color:var(--red)}
.change-card[data-type="weapon"]{border-left-color:var(--blu)}
.change-card[data-type="gameplay"]{border-left-color:var(--orange)}

.change-top{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:center;
}

.change-type{
  display:inline-block;
  margin-right:4px;
  color:#aaa08e;
  font-size:.6rem;
  font-weight:800;
  text-transform:uppercase;
}

.change-date{
  color:#827a6e;
  font-size:.68rem;
}

.change-card h3{
  margin:7px 0 5px;
  color:var(--cream);
  font-size:.95rem;
}

.change-card p{
  margin:0;
  color:var(--muted);
  font-size:.8rem;
  line-height:1.45;
}

.change-card a,
.reference-card a{
  display:inline-block;
  margin-top:8px;
  color:#d78059;
  font-size:.7rem;
  font-weight:800;
  text-transform:uppercase;
}

.reference-card{
  margin-top:14px;
  padding:13px 14px;
  background:#2a2824;
  border:1px solid var(--line);
  border-left:3px solid var(--blu);
  border-radius:3px;
}

.reference-card strong{color:var(--cream)}

.reference-card p{
  margin:5px 0 0;
  color:var(--muted);
  font-size:.8rem;
}

/* Analyzer */

.dropzone{
  padding:38px 20px;
  text-align:center;
  background:var(--panel);
  border:1px dashed #625d55;
  border-radius:3px;
}

.dropzone.drag{
  border-color:var(--orange);
  background:#353029;
}

.cfg-label{
  display:inline-block;
  padding:5px 7px;
  color:#d88b68;
  border:1px solid #8e513b;
  font-size:.8rem;
  font-weight:800;
}

.dropzone h3{
  margin:12px 0 5px;
  color:var(--cream);
  font-size:1rem;
}

.dropzone p{
  margin:0 0 10px;
  color:var(--muted);
  font-size:.8rem;
}

.file-label input{display:none}

.hidden{display:none!important}

.empty-state{
  padding:24px;
  color:#948b7c;
  background:#292722;
  border:1px dashed var(--line);
  text-align:center;
}

.summary{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(140px,1fr));
  gap:8px;
  margin:18px 0;
}

.stat{
  padding:12px;
  background:var(--panel);
  border:1px solid var(--line);
  border-top:2px solid var(--orange);
}

.stat b{
  display:block;
  color:var(--cream);
  font-size:1.25rem;
}

.stat span{
  color:var(--muted);
  font-size:.72rem;
}

.result{
  margin:8px 0;
  padding:13px;
  background:var(--panel);
  border:1px solid var(--line);
}

.result h3{
  margin:0 0 5px;
  color:var(--cream);
  font-size:.95rem;
}

.result p{color:var(--muted)}

.result pre{
  overflow:auto;
  padding:10px;
  color:#ddd2bf;
  background:#1e1d1a;
  border-left:3px solid var(--blu);
  white-space:pre-wrap;
  font:12px/1.5 Consolas,"Courier New",monospace;
}

/* Footer */

footer{
  width:min(1120px,92%);
  margin:0 auto;
  padding:22px 0 28px;
  display:flex;
  justify-content:space-between;
  gap:20px;
  color:#746d62;
  border-top:1px solid #45413b;
  font-size:.67rem;
}

@media(max-width:900px){
  .header-inner{
    align-items:flex-start;
    flex-direction:column;
    padding:10px 0;
  }

  nav{
    width:100%;
    overflow:auto;
    flex-wrap:nowrap;
  }

  .hero{grid-template-columns:1fr}
  .home-links{grid-template-columns:repeat(2,1fr)}
}

@media(max-width:700px){
  .view{padding:36px 0 52px}

  .section-head{
    align-items:stretch;
    flex-direction:column;
  }

  .home-links{grid-template-columns:1fr}
  .command-card{grid-template-columns:1fr}

  .change-top{
    align-items:flex-start;
    flex-direction:column;
  }

  footer{flex-direction:column}
}


/* Weapon changes database */
.weapon-toolbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin:-7px 0 13px;
  padding:9px 10px;
  background:#211f1c;
  border:1px solid var(--line-soft);
  border-radius:3px;
}
.weapon-filter-group{
  display:flex;
  align-items:center;
  gap:8px;
}
.weapon-filter-group label{
  color:#898173;
  font-size:.66rem;
  font-weight:800;
  text-transform:uppercase;
}
.weapon-filter-group select{
  min-height:34px;
  padding:6px 29px 6px 9px;
  color:var(--text);
  background:#292722;
  border:1px solid var(--line);
  border-radius:3px;
}
.weapon-db-stats{
  display:flex;
  align-items:baseline;
  gap:6px;
  color:#827a6e;
  font-size:.68rem;
}
.weapon-db-stats strong{
  color:var(--cream);
  font-size:.9rem;
}
.weapon-grid{
  grid-template-columns:repeat(auto-fit,minmax(290px,1fr));
}
.weapon-card{
  display:flex;
  flex-direction:column;
  min-width:0;
}
.weapon-card-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
}
.weapon-card-head h3{
  margin-bottom:2px;
}
.weapon-count-badge{
  flex:0 0 auto;
  padding:3px 5px;
  color:#d7cbb8;
  background:#24221f;
  border:1px solid #4c4841;
  border-radius:3px;
  font-size:.6rem;
  font-weight:800;
  text-transform:uppercase;
}
.weapon-classname{
  display:block;
  max-width:100%;
  margin-top:7px;
  color:#9e9585;
  overflow-wrap:anywhere;
  font-size:.67rem;
}
.weapon-badges{
  margin-top:3px;
}
.shared-rule-tag{
  border-color:#4f7484;
  color:#a9c2cb;
}
.warning-tag{
  border-color:#8b4c39;
  color:#dda18a;
}
.weapon-details{
  margin-top:12px;
  border-top:1px solid var(--line-soft);
}
.weapon-details>summary{
  padding:10px 0 2px;
  color:#d9865f;
  cursor:pointer;
  font-size:.72rem;
  font-weight:800;
  text-transform:uppercase;
}
.weapon-details>summary:hover{
  color:#eda07b;
}
.weapon-details-body{
  display:grid;
  gap:8px;
  margin-top:10px;
}
.weapon-rule{
  padding:10px;
  background:#272520;
  border:1px solid #444038;
  border-left:3px solid var(--red);
  border-radius:2px;
}
.weapon-rule.classname-rule{
  border-left-color:var(--blu);
}
.weapon-rule-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
}
.weapon-rule-head strong{
  display:block;
  color:var(--cream);
  font-size:.76rem;
}
.weapon-rule-head code{
  display:block;
  margin-top:3px;
  color:#8f8779;
  overflow-wrap:anywhere;
  font-size:.61rem;
}
.weapon-rule-head>span{
  color:#827a6e;
  font-size:.6rem;
  white-space:nowrap;
}
.rule-flags{
  display:flex;
  flex-wrap:wrap;
  gap:5px;
  margin-top:8px;
}
.rule-flag{
  padding:3px 5px;
  color:#aaa18f;
  background:#1e1d1a;
  border:1px solid #454139;
  border-radius:2px;
  font-size:.58rem;
  font-weight:700;
  text-transform:uppercase;
}
.rule-flag.danger{
  color:#dda18a;
  border-color:#784333;
}
.attribute-group{
  margin-top:10px;
}
.rule-group-title{
  margin-bottom:4px;
  color:#9b9283;
  font-size:.6rem;
  font-weight:800;
  letter-spacing:.4px;
  text-transform:uppercase;
}
.custom-attributes .rule-group-title{
  color:#d17c56;
}
.attribute-list{
  border-top:1px solid #3f3b35;
}
.attribute-row{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  padding:5px 0;
  border-bottom:1px solid #3a3731;
  font-size:.68rem;
}
.attribute-row span{
  color:#aaa18f;
}
.attribute-row code{
  flex:0 0 auto;
  color:#e0d5c1;
  font-size:.66rem;
  text-align:right;
}


.player-attribute-list{
  display:grid;
  gap:5px;
  margin-top:5px;
}

.player-attribute-row{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:4px 12px;
  align-items:center;
  padding:8px 9px;
  background:#211f1c;
  border:1px solid #403c35;
  border-left:3px solid #5a554d;
  border-radius:2px;
}

.player-attribute-row.attribute-positive{
  border-left-color:var(--blu);
}

.player-attribute-row.attribute-negative{
  border-left-color:var(--red);
}

.player-attribute-row.attribute-special{
  border-left-color:var(--orange);
}

.player-attribute-label{
  min-width:0;
  color:#c9beaa;
  font-size:.7rem;
  font-weight:700;
  line-height:1.3;
}

.player-attribute-value{
  color:#eadfc8;
  font-size:.7rem;
  text-align:right;
  white-space:nowrap;
}

.player-attribute-note{
  grid-column:1 / -1;
  color:#81796d;
  font-size:.59rem;
  line-height:1.35;
}

.attribute-group-note{
  margin-top:5px;
  padding:8px 9px;
  color:#827a6e;
  background:#211f1c;
  border:1px dashed #403c35;
  font-size:.64rem;
  line-height:1.35;
}

.technical-values{
  margin-top:7px;
  border-top:1px dashed #454139;
}

.technical-values>summary{
  padding:7px 0 1px;
  color:#837b6e;
  cursor:pointer;
  font-size:.59rem;
  font-weight:800;
  letter-spacing:.3px;
  text-transform:uppercase;
}

.technical-values>summary:hover{
  color:#b1a694;
}

.technical-values .attribute-list{
  margin-top:6px;
}

.technical-values .attribute-row{
  padding:5px 7px;
  background:#1f1e1b;
  border:1px solid #393630;
  border-bottom:0;
}

.technical-values .attribute-row:last-child{
  border-bottom:1px solid #393630;
}

@media(max-width:520px){
  .player-attribute-row{
    grid-template-columns:1fr;
  }

  .player-attribute-value{
    text-align:left;
    white-space:normal;
  }
}
.class-override-list{
  margin-top:10px;
  padding-top:9px;
  border-top:1px dashed #49453e;
}
.class-override{
  margin-top:7px;
  padding:8px;
  background:#211f1c;
  border:1px solid #403c35;
}
.class-override>strong{
  color:#e0d4bf;
  font-size:.7rem;
}
.weapon-no-change{
  margin-top:10px!important;
  color:#81796d!important;
  font-size:.7rem!important;
}

@media(max-width:700px){
  .weapon-toolbar{
    align-items:stretch;
    flex-direction:column;
  }
  .weapon-filter-group{
    justify-content:space-between;
  }
  .weapon-filter-group select{
    flex:1;
  }
  .weapon-card-head{
    flex-direction:column;
  }
}

/* Boss category sections */
.boss-category{
  margin-top:18px;
}

.boss-category:first-of-type{
  margin-top:0;
}

.boss-category-head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:12px;
  margin-bottom:8px;
  padding-bottom:7px;
  border-bottom:1px solid var(--line-soft);
}

.boss-category-head h3{
  margin:0;
  color:var(--cream);
  font-size:.95rem;
  text-transform:uppercase;
}

.boss-category-count{
  display:flex;
  align-items:baseline;
  gap:5px;
  color:#827a6e;
  font-size:.66rem;
}

.boss-category-count strong{
  color:var(--cream);
  font-size:.84rem;
}

.boss-category.duo-category .boss-category-head{
  border-bottom-color:#65473d;
}

.boss-category.duo-category .boss-name-item{
  border-left-color:var(--orange);
}

/* Maps */

.map-list-meta{
  display:flex;
  align-items:baseline;
  gap:6px;
  margin:-8px 0 12px;
  color:#827a6e;
  font-size:.68rem;
}

.map-list-meta strong{
  color:var(--cream);
  font-size:.9rem;
}

.map-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(300px,1fr));
  gap:7px;
  align-items:start;
}

.map-entry{
  min-width:0;
  align-self:start;
}

.map-name-item{
  width:100%;
  min-width:0;
  min-height:42px;
  display:flex;
  align-items:center;
  gap:9px;
  padding:8px 10px;
  color:var(--cream);
  background:var(--panel);
  border:1px solid var(--line);
  border-left:3px solid #625d55;
  border-radius:3px;
}

.map-entry:nth-child(odd) .map-name-item{
  border-left-color:var(--red);
}

.map-entry:nth-child(even) .map-name-item{
  border-left-color:var(--blu);
}

.map-toggle{
  appearance:none;
  text-align:left;
  cursor:pointer;
}

.map-toggle:hover,
.map-toggle:focus-visible{
  background:var(--panel-hover);
}

.map-toggle:focus-visible{
  outline:1px solid var(--orange);
  outline-offset:2px;
}

.map-number{
  flex:0 0 auto;
  min-width:25px;
  color:#81796d;
  font-size:.63rem;
  font-weight:800;
  text-align:right;
}

.map-name-item code{
  min-width:0;
  flex:1;
  color:#ddd3c0;
  font-size:.72rem;
  overflow-wrap:anywhere;
}

.map-view-label{
  flex:0 0 auto;
  color:#81796d;
  font-size:.58rem;
  font-weight:800;
  letter-spacing:.35px;
  text-transform:uppercase;
}

.map-toggle-indicator{
  flex:0 0 22px;
  width:22px;
  height:22px;
  display:grid;
  place-items:center;
  margin-left:2px;
  color:#d88a63;
  background:#24221f;
  border:1px solid #4b463f;
  border-radius:2px;
  font-size:.72rem;
  font-weight:800;
  line-height:1;
}

/* Full-screen map viewer */

body.map-viewer-open{
  overflow:hidden;
}

.map-viewer[hidden],
.map-viewer [hidden],
.map-viewer-fallback[hidden],
.map-no-image[hidden]{
  display:none!important;
}

.map-viewer{
  position:fixed;
  inset:0;
  z-index:1000;
  opacity:0;
  visibility:hidden;
  transition:opacity .18s ease,visibility .18s ease;
}

.map-viewer.map-viewer-visible{
  opacity:1;
  visibility:visible;
}

.map-viewer-backdrop{
  position:absolute;
  inset:0;
  background:rgba(10,9,8,.96);
}

.map-viewer-shell{
  position:relative;
  z-index:1;
  width:100%;
  height:100vh;
  height:100dvh;
  display:grid;
  grid-template-columns:88px minmax(0,1fr) 88px;
  grid-template-rows:auto minmax(0,1fr) auto;
  color:var(--text);
  overflow:hidden;
}

.map-viewer-header{
  grid-column:1 / -1;
  grid-row:1;
  min-height:68px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:20px;
  padding:12px 18px;
  background:rgba(31,30,27,.94);
  border-bottom:1px solid #49453e;
}

.map-viewer-heading{
  min-width:0;
  display:flex;
  align-items:baseline;
  gap:12px;
}

.map-viewer-counter{
  flex:0 0 auto;
  color:var(--orange);
  font-size:.68rem;
  font-weight:800;
}

.map-viewer-title{
  min-width:0;
  color:var(--cream);
  font-size:.9rem;
  font-weight:700;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.map-viewer-close{
  flex:0 0 38px;
  width:38px;
  height:38px;
  display:grid;
  place-items:center;
  padding:0;
  color:#e6d8c3;
  background:#282621;
  border:1px solid #514b43;
  border-radius:3px;
  cursor:pointer;
  font-size:1.35rem;
  line-height:1;
}

.map-viewer-close:hover,
.map-viewer-close:focus-visible{
  color:#fff0d4;
  background:#3a302a;
  border-color:#8e513b;
}

.map-viewer-stage{
  grid-column:2;
  grid-row:2;
  min-width:0;
  min-height:0;
  display:grid;
  place-items:center;
  overflow:hidden;
  padding:18px;
}

.map-viewer-slide{
  width:100%;
  height:100%;
  min-width:0;
  min-height:0;
  display:grid;
  place-items:center;
  opacity:1;
  transform:translateX(0);
  transition:transform .18s ease,opacity .18s ease;
  will-change:transform,opacity;
}

.map-viewer-image{
  display:block;
  width:auto;
  height:auto;
  max-width:100%;
  max-height:100%;
  object-fit:contain;
  background:#151412;
  border:1px solid #403c36;
  box-shadow:0 10px 35px rgba(0,0,0,.35);
}

.map-viewer-fallback{
  width:min(720px,100%);
  min-height:240px;
  display:grid;
  place-items:center;
  padding:28px;
  color:#8d8476;
  background:#1c1b18;
  border:1px dashed #514b42;
  font-size:.8rem;
  text-align:center;
}

.map-slide-out-left{
  opacity:0;
  transform:translateX(-12%);
}

.map-slide-out-right{
  opacity:0;
  transform:translateX(12%);
}

.map-slide-in-left{
  opacity:0;
  transform:translateX(-12%);
  transition:none;
}

.map-slide-in-right{
  opacity:0;
  transform:translateX(12%);
  transition:none;
}

.map-viewer-nav{
  grid-row:2;
  align-self:stretch;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:4px;
  padding:8px;
  color:#aaa18f;
  background:transparent;
  border:0;
  cursor:pointer;
}

.map-viewer-prev{
  grid-column:1;
  border-right:1px solid rgba(81,77,69,.35);
}

.map-viewer-next{
  grid-column:3;
  border-left:1px solid rgba(81,77,69,.35);
}

.map-viewer-nav:hover,
.map-viewer-nav:focus-visible{
  color:#fff0d4;
  background:rgba(48,46,41,.55);
}

.map-viewer-arrow{
  font-size:3rem;
  font-weight:400;
  line-height:.8;
}

.map-viewer-nav-label{
  font-size:.58rem;
  font-weight:800;
  letter-spacing:.5px;
  text-transform:uppercase;
}

.map-viewer-hint{
  grid-column:1 / -1;
  grid-row:3;
  min-height:34px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:18px;
  padding:7px 14px;
  color:#716a60;
  background:rgba(24,23,20,.92);
  border-top:1px solid #35322d;
  font-size:.6rem;
  text-transform:uppercase;
}

@media(max-width:700px){
  .map-grid{
    grid-template-columns:1fr;
  }

  .map-view-label{
    display:none;
  }

  .map-viewer-shell{
    grid-template-columns:48px minmax(0,1fr) 48px;
  }

  .map-viewer-header{
    min-height:58px;
    padding:9px 10px;
  }

  .map-viewer-heading{
    gap:7px;
  }

  .map-viewer-title{
    font-size:.72rem;
  }

  .map-viewer-close{
    flex-basis:34px;
    width:34px;
    height:34px;
  }

  .map-viewer-stage{
    padding:9px;
  }

  .map-viewer-arrow{
    font-size:2.35rem;
  }

  .map-viewer-nav-label{
    display:none;
  }

  .map-viewer-hint{
    gap:12px;
    font-size:.52rem;
  }
}
