.cg-root { --cg-burgundy: #a84052; }
.cg-root .cg-tab-content { margin-top: 18px; }
.cg-root h3 { margin: 0 0 10px; font-size: 16px; font-weight: 600; color: inherit; }
.cg-intro { margin-bottom: 15px; }
.cg-map-top { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin: 12px 0 10px; }
.cg-floor-control { margin: 0; font-size: 12px; font-weight: normal; }
.cg-floor-select { display: block; margin-top: 5px; max-width: 100%; padding: 5px 9px; border: 1px solid #46403d; border-radius: 0; background: #242122; color: inherit; font: inherit; }
.cg-root .cg-zoom.btn { border: 1px solid #625a52; border-radius: 0; padding: 4px 10px; background: linear-gradient(180deg, #343230 0%, #272523 100%); color: #d8cfc0; font-family: inherit; font-size: 12px; font-weight: 600; line-height: 1.5; text-shadow: 0 1px 1px #000b; box-shadow: inset 0 1px 0 #ffffff0b, 0 1px 2px #0005; text-decoration: none; }
.cg-root .cg-zoom.btn:hover, .cg-root .cg-zoom.btn:focus { border-color: #827568; background: linear-gradient(180deg, #403c38 0%, #302d29 100%); color: #eee3d1; text-decoration: none; }
.cg-root .cg-zoom.btn:focus-visible { outline: 2px solid #aa9b89; outline-offset: 2px; }
.cg-root .cg-zoom.btn:active { background: #272523; box-shadow: inset 0 1px 3px #0005; }
.cg-frame { display: block; margin: 0; border: 4px solid #46403d; border-image: url('../../tasksystem.png') 4 stretch; background: #1d1c1d; scroll-margin-top: 20px; }
.cg-map-surface { position: relative; line-height: 0; }
.cg-map-surface picture, .cg-map-surface img { display: block; width: 100%; height: auto; }
.cg-map-surface { min-height: 40px; }
.cg-marker-layer { position: absolute; inset: 0; pointer-events: none; }
.cg-marker { position: absolute; display: block; pointer-events: auto; transform: translate(-50%, -50%); box-sizing: border-box; width: 24px; height: 24px; border: 1px solid #b0a28e; border-radius: 50%; background: #242122f2; color: #eee !important; font-family: inherit; font-size: 11px; font-weight: 600; line-height: 22px; text-align: center; text-decoration: none !important; box-shadow: 0 1px 3px #000b; z-index: 1; }
.cg-marker:hover, .cg-marker:focus-visible, .cg-marker.is-selected { border: 2px solid var(--cg-burgundy); outline: 2px solid #6d2231; outline-offset: 1px; background: #42272d; line-height: 20px; z-index: 3; }
.cg-caption { margin: 9px 0 20px; font-size: 12px; color: #aaa; }
.cg-places { border-top: 1px solid #46403d; }
.cg-place { display: flex; gap: 12px; padding: 14px 8px; border-bottom: 1px solid #46403d; scroll-margin-top: 20px; }
.cg-place.is-selected, .cg-place:target { background: #30272b; box-shadow: inset 2px 0 var(--cg-burgundy); }
.cg-place:focus { outline: 1px solid var(--cg-burgundy); outline-offset: -1px; }
.cg-number { flex: 0 0 25px; height: 25px; border: 1px solid #60574e; border-radius: 50%; text-align: center; font-size: 11px; line-height: 23px; font-weight: 600; }
.cg-number--npc { margin-top: 11px; }
.cg-place-copy { min-width: 0; flex: 1; }
.cg-root .cg-place h4 { margin: 0; font-size: 13px; font-weight: 600; line-height: 1.6; color: inherit; }
.cg-place-heading { display: flex; align-items: center; gap: 10px; }
.cg-place-heading > span { min-width: 0; }
.cg-npc-portrait { display: block; flex: 0 0 48px; width: 48px; height: 48px; object-fit: contain; image-rendering: pixelated; }
.cg-place h4 small { display: inline-block; margin-left: 10px; color: #aaa; font: inherit; font-size: 12px; font-weight: normal; }
.cg-place p { margin: 5px 0 9px; }
.cg-place-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; font-size: 12px; }
.cg-floor { color: #aaa; }
.cg-fallback-map, .cg-world img { display: block; max-width: 100%; height: auto; }
.cg-zoom-dialog { width: 1200px; max-width: 94vw; max-height: 94vh; padding: 14px; background: #242122; border: 1px solid #60574e; color: #ccc; }
.cg-zoom-dialog::backdrop { background: #000c; }
.cg-zoom-dialog header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.cg-zoom-scroll { overflow: auto; max-height: 78vh; }
.cg-zoom-scroll .cg-map-surface { width: 1800px; }
.cg-zoom-scroll img { max-width: none; }
.cg-world-link { display: block; max-width: 100%; position: relative; overflow: hidden; cursor: zoom-in; }
.cg-world-lens { position: absolute; display: block; box-sizing: border-box; border: 2px solid #d7c092; border-radius: 50%; background-color: #242122; background-repeat: no-repeat; box-shadow: 0 2px 12px #0008, 0 0 0 1px #685036; pointer-events: none; z-index: 2; }
.cg-world-lens[hidden] { display: none; }
@media (max-width: 600px) {
    .cg-marker { width: 21px; height: 21px; font-size: 10px; line-height: 19px; }
    .cg-marker:hover, .cg-marker:focus-visible, .cg-marker.is-selected { line-height: 17px; }
    .cg-place { padding-left: 3px; padding-right: 3px; gap: 9px; }
    .cg-place h4 small { display: block; margin: 2px 0 0; }
}
