/* Loot-Datenbank Variante B „Atlas & Karten“ (loot.html und die interaktiven SEO-Seiten). Aufbau: lootdb-atlas.js.
   Alles gilt nur mit html.atl-on (setzt lootdb-atlas.js); ohne JavaScript bleibt die bisherige Darstellung.
   Farben aus dem GuildLoot-Rahmen (--gl-*, guildloot-shell.css) mit Rückfallwerten. */
html.atl-on{--atl-bg:var(--gl-bg,#0e1118);--atl-panel:var(--gl-panel,#171c27);--atl-panel2:var(--gl-panel2,#1c2230);--atl-line:var(--gl-line2,rgba(255,255,255,.12));
 --atl-text:var(--gl-text,#edf0f8);--atl-mut:var(--gl-muted,#9aa4b8);--atl-acc:var(--gl-acc,#e9c779);--atl-gold:#e9c779;--atl-r:14px}

/* ---------- Kopf: kein Hero, keine doppelten Versionsknöpfe (die Kopfzeile hat die Versionswahl) ---------- */
html.atl-on:not(.atl-embed) main.wrap>#tabs{display:none}
html.atl-on:not(.atl-embed):not(.gl-lootdb-guild) main.wrap>.k{display:none}
html.atl-on:not(.atl-embed) main.wrap>h1{font:700 28px/1.15 Georgia,"Times New Roman",serif;margin:0 0 4px}
html.atl-on:not(.atl-embed) main.wrap>.sub{font-size:15px;margin:0 0 14px;color:var(--atl-mut)}
html.atl-on:not(.atl-embed) main.wrap>.search input{border-color:var(--atl-line);background:var(--atl-panel);border-radius:12px;padding:12px 16px;font-size:16px}
html.atl-on:not(.atl-embed) main.wrap>.search input:focus{border-color:var(--atl-gold);outline:none}
html.atl-on:not(.atl-embed) main.wrap>.search .btn{padding:12px 20px;border-radius:12px;background:var(--atl-panel2);color:var(--atl-text);border:1px solid var(--atl-line)}
/* Startansicht: zentrierte Suche */
html.atl-home:not(.atl-embed) main.wrap>h1,html.atl-home:not(.atl-embed) main.wrap>.sub,html.atl-home:not(.atl-embed) main.wrap>.k{text-align:center}
html.atl-home:not(.atl-embed) main.wrap>h1{font-size:34px;margin-top:10px}
html.atl-home:not(.atl-embed) main.wrap>.search{max-width:780px;margin:0 auto}
html.atl-home #filters{display:none!important}

/* ---------- Kein Kategorienbaum, keine rechte Spalte: Liste über die volle Breite ---------- */
html.atl-on #atlasNav,html.atl-on .gl-atlas-fold{display:none!important}
html.atl-on #hot{display:none!important}
html.atl-on .grid,html.atl-on .gldb-grid{display:block;margin-top:14px}
html.atl-on .gldb-grid>.gldb-main{min-width:0}

/* ---------- Brotkrümel-Navigator ---------- */
html.atl-on .atl-crumbs{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:14px 0 4px}
html.atl-on .atl-crumbs[hidden]{display:none}
html.atl-on .atl-back{display:inline-flex;align-items:center;min-height:36px;padding:0 14px;border:1px solid var(--atl-line);border-radius:999px;color:var(--atl-text);text-decoration:none;font-size:14px;background:var(--atl-panel)}
html.atl-on .atl-back:hover{border-color:var(--atl-gold)}
html.atl-on .atl-sep{color:var(--atl-mut)}
html.atl-on .atl-sep[hidden]{display:none}
html.atl-on .atl-crumbs .f.atl-pill{display:inline-flex!important;align-items:center;gap:4px;min-height:36px;border:1px solid var(--atl-line);border-radius:999px;padding:0 6px 0 14px;background:var(--atl-panel);font-size:14px;color:var(--atl-mut)}
html.atl-on .atl-crumbs .f.atl-pill[hidden]{display:none!important}
html.atl-on .atl-crumbs .f.atl-pill select{background:transparent;border:0;color:var(--atl-text);font-weight:700;font-size:14px;max-width:260px;padding:6px 2px;cursor:pointer}
html.atl-on .atl-crumbs .f.atl-pill select option,html.atl-on .atl-crumbs .f.atl-pill select optgroup{background:#171c27;color:#edf0f8}

/* ---------- Boss-Leiste ---------- */
html.atl-on .atl-bosses{display:flex;gap:10px;overflow-x:auto;padding:4px 2px 10px;margin:6px 0 4px;scrollbar-width:thin;scroll-snap-type:x proximity}
html.atl-on .atl-bosses[hidden]{display:none}
html.atl-on .atl-boss{flex:0 0 auto;display:flex;flex-direction:column;align-items:center;gap:4px;width:112px;padding:10px 8px;border:1px solid var(--atl-line);border-radius:var(--atl-r);background:var(--atl-panel);color:var(--atl-text);cursor:pointer;scroll-snap-align:start;font:inherit;text-align:center}
html.atl-on .atl-boss:hover{border-color:rgba(233,199,121,.55)}
html.atl-on .atl-boss[aria-pressed=true]{border-color:var(--atl-gold);background:linear-gradient(180deg,rgba(233,199,121,.14),var(--atl-panel))}
html.atl-on .atl-bpic{width:56px;height:56px;border-radius:50%;display:grid;place-items:center;overflow:hidden;background:var(--atl-panel2);border:1px solid var(--atl-line);color:var(--atl-gold);font-size:22px}
html.atl-on .atl-bpic img{width:100%;height:100%;object-fit:cover;display:block}
html.atl-on .atl-bname{font-weight:700;font-size:13px;line-height:1.25;overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow-wrap:break-word;-webkit-hyphens:auto;hyphens:auto}
html.atl-on .atl-boss small{color:var(--atl-mut);font-size:12px}
html.atl-on .atl-bosses.atl-plain .atl-boss{width:auto;max-width:260px;flex-direction:row;padding:8px 14px;border-radius:999px;gap:8px}
html.atl-on .atl-bosses.atl-plain .atl-bname{-webkit-line-clamp:1;white-space:nowrap;text-overflow:ellipsis;display:block}
html.atl-on .f.atl-bosssel{display:none!important}

/* ---------- Filterzeile ---------- */
html.atl-on #filters{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:8px 0 12px}
html.atl-on #filters .f,html.atl-on #filters .chk{min-height:36px;border:1px solid var(--atl-line);background:var(--atl-panel);border-radius:999px}
html.atl-on #filters .f select{font-size:14px}
html.atl-on #filters .f.atl-cls .atl-ci{border-radius:50%;margin-right:2px}
html.atl-on .atl-for{display:inline-flex;align-items:center;gap:6px;min-height:36px;padding:0 14px 0 10px;border:1px solid var(--atl-line);border-radius:999px;background:var(--atl-panel);color:var(--atl-text);font:inherit;font-size:14px;cursor:pointer}
html.atl-on .atl-for .atl-for-k{color:var(--atl-mut)}
html.atl-on .atl-for.on{border-color:var(--atl-gold);background:rgba(233,199,121,.10)}
html.atl-on .atl-for .atl-ci,html.atl-on .atl-for .atl-ri{border-radius:50%}
html.atl-on .atl-view{display:inline-flex;margin-left:auto;border:1px solid var(--atl-line);border-radius:999px;overflow:hidden}
html.atl-on .atl-view[hidden]{display:none}
html.atl-on .atl-view button{border:0;background:var(--atl-panel);color:var(--atl-mut);font:inherit;font-size:14px;padding:0 14px;min-height:34px;cursor:pointer}
html.atl-on .atl-view button[aria-pressed=true]{background:var(--atl-panel2);color:var(--atl-text);font-weight:700}

/* ---------- Liste: Startansicht mit Kategorie-Kacheln (alles zugeklappt) ---------- */
html.atl-on #list{background:transparent;border:0}
html.atl-on #list.atl-home>.boss,html.atl-on #list.atl-home>.cards~.boss.sec,html.atl-on #list.atl-home>.cards~.cards{display:none}
html.atl-on #list .cards.atl-tiles{grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:14px;padding:18px 0}
html.atl-on #list .atl-tiles .gc{position:relative;display:flex;flex-direction:column;justify-content:flex-end;min-height:0;aspect-ratio:1/1;max-height:240px;padding:0;overflow:hidden;border:1px solid var(--atl-line);border-radius:var(--atl-r);background:var(--atl-panel)}
html.atl-on #list .atl-tiles .gc:hover{border-color:var(--atl-gold);transform:translateY(-1px)}
html.atl-on #list .atl-tiles .atl-art{position:absolute;inset:0;overflow:hidden}
html.atl-on #list .atl-tiles .atl-art img{width:100%;height:100%;object-fit:cover;object-position:center 45%;display:block}
html.atl-on #list .atl-tiles .atl-art::after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(14,17,24,0) 35%,rgba(14,17,24,.82) 72%,rgba(14,17,24,.96))}
html.atl-on #list .atl-tiles .gc b{position:relative;padding:0 14px;font:700 17px/1.25 Georgia,serif;color:var(--atl-text);text-shadow:0 1px 3px rgba(0,0,0,.8)}
html.atl-on #list .atl-tiles .gc small{position:relative;padding:2px 14px 12px}
/* Übersicht einer Kategorie (Gruppen als Karten) */
html.atl-on #list:not(.atl-home)>.cards{padding:12px 0}
html.atl-on #list .gc{background:var(--atl-panel);border-color:var(--atl-line);border-radius:12px}
html.atl-on #list>.boss{padding:12px 4px;border-bottom:0}
html.atl-on #list>.boss.sec{background:transparent;margin-top:6px;border-bottom:1px solid var(--atl-line);font-size:15px;color:var(--atl-mut)}
html.atl-on #list .gh{font-size:22px}

/* ---------- Itemzeilen: ☆ statt großem Knopf ---------- */
html.atl-on #list .row .add{width:40px;height:40px;padding:0;border-radius:50%;font-size:0;line-height:0;display:grid;place-items:center;justify-self:end;border-color:var(--atl-line);color:var(--atl-mut);background:transparent}
html.atl-on #list .row .add::before{content:"☆";font-size:20px;line-height:1}
html.atl-on #list .row .add:hover{border-color:var(--atl-gold);color:var(--atl-gold)}
html.atl-on #list .row .add[aria-pressed=true]{background:transparent;color:var(--atl-gold);border-color:var(--atl-gold)}
html.atl-on #list .row .add[aria-pressed=true]::before{content:"★"}
html.atl-on #list .pop .atl-ci{border-radius:50%;vertical-align:-3px;margin-right:3px}

@media (min-width:701px){
 /* Tabelle: dicht, wie bisher, aber mit ☆ */
 html.atl-on #list.atl-table{border:1px solid var(--atl-line);border-radius:var(--atl-r);background:var(--atl-panel);overflow:hidden}
 html.atl-on #list.atl-table>.boss{padding:12px 18px}
 html.atl-on #list.atl-table .row{grid-template-columns:36px minmax(0,1fr) 220px 44px;padding:9px 18px}
 /* Karten: drei Spalten, Zwischenüberschriften über die ganze Breite */
 html.atl-on #list.atl-cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:10px}
 html.atl-on #list.atl-cards>:not(.row){grid-column:1/-1}
 html.atl-on #list.atl-cards .row{grid-template-columns:40px minmax(0,1fr) 40px;grid-template-areas:"ic nm add" "pop pop pop";align-items:start;gap:8px 12px;padding:12px 14px;border:1px solid var(--atl-line);border-radius:var(--atl-r);background:var(--atl-panel)}
 html.atl-on #list.atl-cards .row:hover,html.atl-on #list.atl-cards .row.hover{border-color:rgba(233,199,121,.5);background:var(--atl-panel2)}
 html.atl-on #list.atl-cards .row>.icl{grid-area:ic}
 html.atl-on #list.atl-cards .row .ic{width:40px;height:40px}
 html.atl-on #list.atl-cards .row>.nm{grid-area:nm}
 html.atl-on #list.atl-cards .row>.pop{grid-area:pop;border-top:1px solid var(--atl-line);padding-top:8px}
 html.atl-on #list.atl-cards .row>.add{grid-area:add}
 html.atl-on #list.atl-cards .row>.tokd{grid-column:1/-1;margin:0}
 html.atl-on #list.atl-cards .row.is-current{box-shadow:inset 3px 0 0 var(--green,#9be56a)}

 /* Detail-Panel rechts (Deep-Link ?item=, Esc schließt) */
 dialog.gl-itemdlg{margin:0 0 0 auto;width:min(440px,100vw);max-width:none;height:100vh;height:100dvh;max-height:none;border-radius:16px 0 0 16px;border-right:0;padding:22px 22px 28px;overflow:auto;background:var(--atl-panel,#171c27)}
 dialog.gl-itemdlg[open]{animation:atl-in .18s ease-out}
 @keyframes atl-in{from{transform:translateX(24px);opacity:.6}to{transform:none;opacity:1}}

 /* Schwebende Knöpfe + Drawer */
 html.atl-on .atl-fab{position:fixed;right:16px;bottom:16px;z-index:8300;display:flex;flex-direction:column;align-items:flex-end;gap:8px}
 /* Kompakt: runde Symbolknöpfe (Name bleibt für Screenreader); reicht der Rand nicht, hält die Seite rechts Platz frei */
 html.atl-on .atl-fab button{position:relative;width:52px;height:52px;min-height:0!important;padding:0!important;justify-content:center;border-radius:50%!important}
 html.atl-on .atl-fab .atl-fab-t{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
 html.atl-on .atl-fab .atl-fab-i{font-size:22px}
 html.atl-on .atl-fab .atl-sack{width:28px;height:28px}
 html.atl-on .atl-fab b{position:absolute;top:-4px;right:-4px}
 html.atl-fab-pad main.wrap{padding-right:84px}
 html.atl-on .atl-fab button{display:inline-flex;align-items:center;gap:8px;min-height:46px;padding:0 16px;border-radius:12px;border:1px solid var(--atl-line);background:var(--atl-panel);color:var(--atl-text);font:700 15px -apple-system,"Segoe UI",sans-serif;cursor:pointer;box-shadow:0 10px 30px rgba(0,0,0,.45)}
 html.atl-on .atl-fab .atl-fab-w{background:var(--atl-gold);color:#1a1405;border-color:var(--atl-gold)}
 html.atl-on .atl-fab b{min-width:22px;height:22px;padding:0 6px;border-radius:11px;background:#1a1405;color:var(--atl-gold);font-size:13px;display:inline-grid;place-items:center}
 html.atl-on .atl-fab b[hidden]{display:none}
 html.atl-on .atl-sack{border-radius:5px;display:block}
 html.atl-on aside.atl-drawer{position:fixed;top:0;right:0;bottom:0;z-index:9100;width:min(420px,100vw);overflow:auto;padding:52px 18px 24px;background:var(--atl-bg);border-left:1px solid var(--atl-line);box-shadow:-20px 0 50px rgba(0,0,0,.5);transform:translateX(105%);transition:transform .2s ease;visibility:hidden}
 html.atl-open-char aside.atl-drawer,html.atl-open-wish aside.atl-drawer{transform:none;visibility:visible}
 html.atl-open-char aside.atl-drawer #wlCard,html.atl-open-wish aside.atl-drawer #charCard{display:none}
 html.atl-on aside.atl-drawer .card{background:transparent;border:0;padding:0;margin:0}
 html.atl-on .atl-x{position:absolute;top:8px;right:10px;width:40px;height:40px;border:0;background:transparent;color:var(--atl-mut);font-size:28px;cursor:pointer}
 html.atl-on .atl-shade{display:none}
 html.atl-open-char .atl-shade,html.atl-open-wish .atl-shade{display:block;position:fixed;inset:0;z-index:9090;background:rgba(0,0,0,.45)}
 html.atl-on #wlTitle{display:flex;align-items:center;gap:10px}
 html.atl-on #wlTitle .atl-sack{border-radius:6px}
 html.atl-on main.wrap,html.atl-on .wrap.gldb-on{padding-bottom:90px}
}

/* ---------- Eine dezente Anmelde-Zeile unter der Liste (öffentlich; im Gildenkontext versteckt lootdb-guild.js sie) ---------- */
html.atl-on .atl-signup{margin:18px 0 0;padding:10px 4px 0;border-top:1px solid var(--atl-line);font-size:14px;color:var(--atl-mut);text-align:center}
html.atl-on .atl-signup[hidden]{display:none}
html.atl-on .atl-signup a{color:var(--atl-gold)!important}

/* ---------- SEO-Seiten: statischer Inhalt bleibt, Doppelungen weg ---------- */
html.atl-embed .seo-static .cta{display:none}
/* Versionswahl nur in der Kopfzeile (wie loot.html) */
html.atl-embed .gldb-bar>.tabs{display:none!important}
html.atl-embed .gldb-bar>.tabs .tab{padding:4px 12px;border-radius:999px;font-size:14px;background:var(--atl-panel);border-color:var(--atl-line)}
html.atl-embed .gldb-bar>.tabs .tab img{height:20px}
html.atl-embed .gldb-bar>.tabs .tab[aria-selected=true]{border-color:var(--atl-gold)}
html.atl-embed .gldb .search input{border-color:var(--atl-line);background:var(--atl-panel);padding:11px 16px;font-size:16px}
html.atl-embed .gldb .search .btn{padding:11px 18px;background:var(--atl-panel2);color:var(--atl-text);border:1px solid var(--atl-line)}
html.atl-embed .gldb-ui .card#list{border:0}
html.atl-on .seo-static .bars .atl-ci{border-radius:50%;vertical-align:-4px;margin-right:6px}

/* ---------- Handy (lootdb-mobile.js setzt html.mdb-on bis 700 px) ---------- */
@media (max-width:700px){
 html.atl-on .atl-fab,html.atl-on .atl-shade,html.atl-on .atl-x,html.atl-on .atl-view,html.atl-on .atl-for{display:none!important}
 html.atl-on .atl-crumbs{display:none}
 html.atl-on .mdb-chips .mdb-l3{display:none!important}
 html.atl-home .mdb-chips{display:none!important}
 html.atl-on .atl-bosses{margin:8px -16px 4px;padding:4px 16px 8px;gap:8px;scrollbar-width:none}
 html.atl-on .atl-bosses::-webkit-scrollbar{display:none}
 html.atl-on .atl-boss{flex-direction:row;width:auto;max-width:220px;min-height:44px;padding:4px 12px 4px 4px;border-radius:999px;gap:8px}
 html.atl-on .atl-bosses.atl-plain .atl-boss{padding:4px 14px}
 html.atl-on .atl-bpic{width:34px;height:34px;font-size:16px}
 html.atl-on .atl-bname{-webkit-line-clamp:1;white-space:nowrap;display:block;text-overflow:ellipsis;font-size:14px}
 html.atl-on .atl-boss small{display:none}
 html.atl-on #list .cards.atl-tiles{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;padding:12px 0}
 html.atl-on #list .atl-tiles .gc{min-height:160px}
 html.atl-on #list .atl-tiles .gc b{font-size:15px;padding:0 10px}
 html.atl-on #list .atl-tiles .gc small{padding:2px 10px 10px;font-size:13px}
 html.atl-home:not(.atl-embed) main.wrap>h1{font-size:26px}
 html.atl-on #list{border:1px solid var(--atl-line);border-radius:var(--atl-r);background:var(--atl-panel)}
 html.atl-on #list.atl-home{border:0;background:transparent}
 /* Lootsack in der unteren Leiste (Wunschliste) */
 html.atl-on .mdb-dock button:nth-child(2)::before{content:"";width:22px;height:22px;border-radius:5px;background:url(images/lootdb/lootsack.png) center/cover no-repeat;flex:0 0 auto}
 html.atl-on #list .row .add{width:44px;height:44px}
}
@media (max-width:900px){html.atl-embed #filters.is-collapsed{display:none}}
/* Handy: Version nur einmal (Kopfzeile „Era ▾“); Startansicht ohne Filterknopf */
@media (max-width:700px){
 html.atl-on:not(.atl-embed) .mdb-tools>select{display:none}
 html.atl-on:not(.atl-embed) .mdb-tools>button{flex:1 1 auto}
 html.atl-home .mdb-tools{display:none!important}
}
/* Handy: Lootsack auch im Kopf des Wunschlisten-Sheets */
@media (max-width:700px){
 html.atl-on .mdb-sheet:has(#wlCard) .mdb-sheet-h h2{display:flex;align-items:center;gap:8px}
 html.atl-on .mdb-sheet:has(#wlCard) .mdb-sheet-h h2::before{content:"";width:26px;height:26px;border-radius:6px;background:url(images/lootdb/lootsack.png) center/cover no-repeat;flex:0 0 auto}
}
/* Kachelzahlen und Hinweise */
html.atl-on #list .atl-tiles .gc small.atl-tilenote{padding-top:0;margin-top:-10px;font-size:12px;color:var(--atl-mut);opacity:.9}
html.atl-on .atl-catnote{margin:6px 2px 8px;color:var(--atl-mut);font-size:14px}
html.atl-on .atl-catnote[hidden]{display:none}
/* Handy: Rollen-Symbole nicht mit dem Text abschneiden – rechts in der Zeile, der Text kürzt sich davor */
@media (max-width:700px){
 html.mdb-on #list .row .nm small{position:relative}
 html.mdb-on #list .row .nm small[data-atl-roles="1"]{padding-right:22px}
 html.mdb-on #list .row .nm small[data-atl-roles="2"]{padding-right:42px}
 html.mdb-on #list .row .nm small[data-atl-roles="3"]{padding-right:62px}
 html.mdb-on #list .row .nm small>.atl-roles{position:absolute;right:0;top:50%;transform:translateY(-50%);margin:0;background:var(--atl-panel,#171c27);padding-left:2px}
}
