/* dE16zg4.css - changed bar-bgs*/

/* Total silliness*/
#splashScreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #5e1a86;
    /* Deep purple */
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.5em;
    font-family: "Bungee Hairline", sans-serif;
    /*alternately: "Jolly Lodger", serif, system-ui;*/
    z-index: 9999;
    transition: opacity 1s ease-in-out;
}

#splashScreen.fade-out {
    opacity: 0;
    pointer-events: none;
}

button#newCharBtn.getBig {
    transform: scale(3);
    transition: transform 0.5s ease-in-out;
    border: 2px solid #0f0;
}

button#newCharBtn.getSmall {
    transform: scale(-3);
    transition: transform 0.5s ease-in-out;
    border: 2px solid #0f0;
}

button#newCharBtn.getBig.pulsing {
    animation: pulse 1s infinite;
}

/* Wil'o-the-Wisp */
.particle {
    position: absolute;
    width: 10px;
    height: 10px;
    background: radial-gradient(circle, #ffffff, #ffccff, transparent);
    border-radius: 50%;
    pointer-events: none;
    z-index: 10000;
    box-shadow: 0 0 10px #fff, 0 0 20px #ff66ff;
    animation: flicker 0.3s infinite alternate;
}

.stat-bar-bg {
    background: #253325;
    border-radius: 12px;
    height: 18px;
    position: relative;
}

.stat-god {
    background-color: rgb(0, 110, 255);
}

.stat-demigod {
    background-color: rgb(27, 168, 211);
}

.stat-heroic {
    background-color: rgb(38, 182, 146)
}

.stat-skillful {
    background-color: rgb(106, 168, 34);
}

.stat-average {
    background-color: rgb(199, 199, 48);
}

.stat-terrible {
    background-color: rgb(116, 59, 49);
}

.stat-handicapped {
    background-color: rgb(65, 41, 41);
}

@keyframes flicker {
    0% {
        transform: scale(1) translate(0, 0);
        opacity: 0.8;
    }

    100% {
        transform: scale(1.3) translate(1px, -1px);
        opacity: 1;
    }
}

/* Flash effect on #storyLog */
@keyframes flashEffect {
    0% {
        background-color: inherit;
    }

    50% {
        background-color: #444 !important;
    }

    /* Brighter flash */
    100% {
        background-color: inherit;
    }
}

/* For Webkit browsers (Chrome, Edge, Safari) */
body::-webkit-scrollbar {
    width: 12px;
    background: #181818;
    /* track */
}

body::-webkit-scrollbar-thumb {
    background: linear-gradient(120deg, #253326 60%, #374b3e 100%);
    border-radius: 9px;
    border: 2px solid #265a33;
    /* mid/dark green */
    min-height: 24px;
    box-shadow: 0 0 8px #18211860 inset;
}

body::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(120deg, #2d4c37 60%, #43604e 100%);
    border-color: #3fa36c;
}

body::-webkit-scrollbar-corner {
    background: #222;
}

body::-webkit-scrollbar:horizontal {
    display: none;
    /* Hide horizontal scrollbar */
}

/* Actual meat n bones*/
body {
    background-color: #121212;
    color: #f5f5f5;
    font-family: "Averia Gruesa Libre", system-ui;
    /* alternately: "Oldenburg", serif;*/
    font-weight: 400;
    font-style: normal;
    /* padding: 2em; */
    /* Body padding is what messed up the alignment, along with gap:2em in .main-layout */
    text-align: center;
    scrollbar-width: thin;
    scrollbar-color: #263e31 #181818;
    /* thumb, track */
    overflow-y: auto;
    /* Show vertical scrollbar only if needed */
    overflow-x: hidden;
    /* Never show horizontal scrollbar */
}

.main-layout {
    display: flex;
    justify-content: space-between;
    /* gap: 2em; */
    /* Never use this. This is the enemy. */
    max-width: 1350px;
    /* Or whatever fits your design */
    margin: 0 auto;
    /* This centers the flex container horizontally */
}

/* default is hidden until the page loads */
#pageFooter,
#header,
#leftPanel,
#centerPanel,
#rightPanel {
    display: none;
}

/* Gonna try adjusting the UI now */
#leftPanel,
#rightPanel {
    width: 10%;
    max-width: 150px;
    min-width: 100px;
}

#centerPanel {
    width: 100%;
}

#statsDisplay {
    max-height: 600px;
    overflow-y:auto;
    overflow-x:hidden;
}

#virtuesDisplay {
    max-height: 600px;
    /* overflow: scroll; */
    overflow-y:auto;
    overflow-x:hidden;
}

#netDisplay {
    /* your char's network is displayed here*/
    max-height: 300px;
    overflow: auto;
}

/* storylog container */
.tab-story {
    scrollbar-width: none;
    width: 100%;
    justify-content: center;
}

/* overlay appearance when viewing map */
#centerPanel {
    position: relative;
}

#tab-story.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 60%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    z-index: 1;
    overflow-y: auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.tab-buttons {
    position: fixed;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 0.5em;
    margin-bottom: 0;
    z-index: 1000;
}

.tab-buttons button {
    flex: 1;
    background-color: #222;
    border: 1px solid #555;
    color: white;
    padding: 0.5em;
    cursor: pointer;
}

.tab-buttons button:hover {
    background-color: #333;
}

.tab-buttons button.active {
    border: 2px solid #06e624;
    border-radius: 3px;
    background-color: #333;
    box-shadow: 0 0 6px #06c45588;
    font-weight: bold;
    z-index: 2;
}

.tab-content {
    display: none;
}

.tab-content.active,
.tab-content:target {
    display: block;
    /* word-wrap: break-word;
    overflow-x: hidden; */
}

#relsDisplay {
    max-width: 100%;
    width: 100%;
    overflow-x: auto;
}

h1 {
    margin-bottom: 0.5em;
    font-family: "Bungee Hairline", serif;
    /*alternately: "Jolly Lodger", serif, system-ui;*/
    font-weight: 900;
    font-size: xx-large;
    font-style: normal;
}

h2 {
    font-family: "Bungee Hairline", serif;
    /*alternately: "Jolly Lodger", serif, system-ui;*/
    font-weight: 850;
    font-size: x-large;
    font-style: normal;
}

h3 {
    font-family: "Bungee Hairline", serif;
    /*alternately: "Jolly Lodger", serif, system-ui;*/
    font-weight: 800;
    font-size: large;
    font-style: normal;
}

.centered {
    display: flex;
    justify-content: center;
    margin-top: 1em;
}

.smallcap {
    font-variant: small-caps;
}

.rels-bar-bg {
    position: relative;
    /* or #333 */
    background-color: #573f54;
    border-radius: 12px;
    height: 20px;
    width: 100%;
    overflow: hidden;
    margin-top: 4px;
}

.rels-bar-top {
    position: absolute;
    left: 0;
    top: 0;
    height: 50%;
    background: rgb(245, 90, 193);
    border-radius: 12px 12px 0 0;
    width: var(--top-width, 0%);
    transition: width 0.3s;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.6);
}

.rels-bar-bottom {
    position: absolute;
    left: 0;
    top: 50%;
    height: 50%;
    background: rgb(141, 55, 180);
    border-radius: 0 0 12px 12px;
    width: var(--bottom-width, 0%);
    transition: width 0.3s;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.6);
}

.rels-bar-label {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 100%;
    color: #fff;
    text-align: center;
    line-height: 1.3em;
    font-size: clamp(9px, 1.2vw, 11px);
    padding: 0 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    pointer-events: none;
    z-index: 2;
}

.rels-bar-bg.faded {
    opacity: 0.25;
}

.rel-line2 {
    font-size: 0.93em;
    color: #ccc;
}

.relsbarmarg {
    margin: 5px 0 0 0;
}

.rel-list {
    list-style: none;
    width: 100%;
    max-width: 100%;
    padding: 0;
    margin: 0;
}

.rel-gender {
    color: #888;
    margin-left: 8px;
}

.rel-affin {
    margin-left: 18px;
    font-size: 0.95em;
    color: #88f;
}

.rel-row {
    padding: 0.4em 0 0.4em 0.2em;
    border-bottom: 1px solid #242035;
    background: rgba(40, 18, 60, 0.25);
    border-radius: 0.4em;
    box-shadow: 0 0.2em 0.3em #0008;
    display: flex;
    flex-wrap: wrap;
    /* align-items:baseline; */
    gap: 0.8em;
    font-size: .9em;
    font-weight: 400;
    transition: background 0.2s;
}

.rel-row:hover {
    background: rgba(120, 90, 180, 0.10);
}

.rel-mainline {
    /* display: flex;
    align-items: baseline;
    justify-content: space-between;
    flex-wrap: nowrap; */
    /* gap: 0.8em; */
    width: 100%;
    max-width: 100%;
    font-size: clamp(0.7em, 2.5vw, 1.15em);
    font-weight: 450;
    white-space: nowrap;
    overflow: auto;
    /* text-overflow: ellipsis; */
    margin-bottom: 0.1em;
    color: #fff;
}

.rel-h3 {
    font-weight: bold;
    color: #ffd1ff;
    font-size: .9em;
    letter-spacing: 0.02em;
}

.rel-h3.deceased {
    color: grey;
}

.rel-h2 {
    color: #90e0fb;
    font-style: italic;
}

.rel-h1 {
    color: #ffd28d;
    margin-left: 1.2em;
    font-size: 0.99em;
    font-style: italic;
    font-weight: 400;
}

.rel-h1.deceased {
    color: grey;
}

.rel-h4 {
    color: #cfcfcf;
    font-size: 0.8em;
}

.rel-secondary {
    font-size: 0.95em;
    color: #b4a6f5;
    margin-bottom: 0.14em;
}

.rel-bond {
    font-style: italic;
    color: #f6baff;
    font-size: .8em;
    margin-left: 1em;
}

.rel-bar-wrap {
    margin-top: .2em;
    margin-bottom: 0;
    width: 100%;
}

.virtue {
    margin: 0 0 0.75em 0;
    display: flex;
    align-items: left;
}

.virtue-icon-col {
    width: 1.5em;
    text-align: center;
    font-size: 1.2em;
}


.stat {
    margin: 10px 6px;
    /* display: flex;
    align-items: center; */
}

.drive {
    margin: 0.75em;
    display: flex;
    align-items: center;
}


.drive-icon-col {
    width: 1.5em;
    text-align: center;
    font-size: 1.2em;
}

.drive-info {
    flex-grow: 1;
    text-align: left;
}

.label {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.25em;
    margin-bottom: 0.25em;
    font-size: 0.9em;
}

.drive-name {
    cursor: pointer;
    text-decoration: underline;
    text-decoration-thickness: .25px;
    size:.75em;
}

.virtue-bar-bg {
    background-color: #303f50;
    border-radius: 12px;
    height: 20px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    /* When used inside .bar-row ensure the bar stretches
       across the remaining horizontal space */
    flex-grow: 1;
    width: 100%;
}

.bar-bg {
    background-color: #472d2d;
    border-radius: 12px;
    height: 20px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    /* When used inside .bar-row ensure the bar stretches
       across the remaining horizontal space */
    flex-grow: 1;
    width: 100%;
    min-width: 175px;
    max-width: 250px;
}

/* Drive bars override flex behaviour so JS-defined width is respected */
.drive-bar-bg {
    flex-grow: 0;
    width: auto;
}

.bar-fill {
    height: 100%;
    background-color: #28a745;
    width: 50%;
    transition: width 0.3s;
    border-radius: 12px;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.6);
}

.bar-bg.dimmed {
    opacity: 0.3;
}

.bar-bg.active {
    outline: 2px solid #0f0;
    opacity: 1;
}

.drive-action-text {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
    color: #fff;
    text-shadow: 0 0 3px #000;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0 4px;
    font-size: 0.8em;
}

/* Row containing decay indicator and the bar itself */
.bar-row {
    display: flex;
    align-items: center;
    gap: 0.4em;
}

.decay-rate {
    font-size: 0.8em;
    white-space: nowrap;
    margin-left: 0.25em;
}

.bar-container,
.rel-bar-wrap,
.rel-row {
    width: min(96%, 1050px);
    margin: 0.4em auto;
    box-sizing: border-box;
}

.bar-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

button {
    font-family: "Averia Gruesa Libre", system-ui;
    /* alternately: "Oldenburg", serif;*/
    margin: 1em 0.5em;
    padding: 0.6em 1.2em;
    background-color: #222;
    color: #f5f5f5;
    border: 1px solid #444;
    border-radius: 5px;
    cursor: pointer;
}

button:hover {
    background-color: #333;
}

.danger {
    background-color: #dc3545 !important;
}

.warning {
    background-color: #ffc107 !important;
}

.shadowGear {
    color: #ff4444;
    font-weight: bold;
}

/* Tooltip for Drives & Virtues*/
#tooltip {
    position: fixed;
    background-color: #1f1f1f;
    border: 1px solid #252525;
    padding: 1em;
    max-width: 300px;
    border-radius: 8px;
    z-index: 100;
    display: none;
    text-align: left;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.6);
}

/* Tooltip for Factions*/
.tooltip-box {
    /* Tooltip for Drives & Virtues pt 1 of 2*/
    position: absolute;
    /* anchored to main container or document body */
    z-index: 1000;
    max-width: 280px;
    padding: 8px 12px;
    background: #1b1b1b;
    color: #636363;
    border: 1px solid #666;
    border-radius: 6px;
    font-size: 0.9em;
    line-height: 1.4;
    pointer-events: none;
}

.clickable-faction {
    /* Tooltip for Drives & Virtues pt 2 of 2*/
    color: #4eb1e2;
    text-decoration: underline;
    text-decoration-thickness: .5px;
    cursor: pointer;
}

.lore-link {
    color: #4eb1e2;
    cursor: pointer;
    text-decoration: underline;
}

/* Anyway, back to layout stuff...*/
.column {
    flex: 1;
    min-width: 280px;
}

.story-log {
    background-color: #1a1a1a;
    border: 1px solid #333;
    padding: 1em;
    height: 300px;
    overflow-y: auto;
    text-align: left;
    font-size: 0.9em;
    border-radius: 8px;
}

#actionMenu{
    margin: 2em 2em 2em 2em;
    text-align:center;
}

.drive-actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    flex-direction: column;
    flex-wrap:wrap;
    position:relative;
    gap: 0.5em;
    width: 100%;
    margin: 1em auto 0 auto;
}

.drive-actions button {
    font-family: "Averia Gruesa Libre", system-ui;
    /* alternately: "Oldenburg", serif;*/
    width: 100%;
    margin: 0;
    /* Remove default margin for tight grid fit */
    box-sizing: border-box;
    font-family: "Averia Gruesa Libre", system-ui;
    padding: 0.5em 0.5em;
    font-size: 0.75em;
    background-color: #292929;
    border: 1px solid #555;
    color: white;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.2s;
}

.drive-actions button:hover {
    background-color: #444;
}

.drive-btn {
    opacity: 1;
    transition: 0.2s;
}

.drive-btn.dimmed {
    opacity: 0.3;
}

.drive-btn.active {
    border: 2px solid #0f0;
    opacity: 1;
}

#endTurnBtn.pulsing {
    animation: pulse 1s infinite;
    border: 2px solid #0f0;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 5px #0f0;
    }

    50% {
        box-shadow: 0 0 20px #0f0;
    }

    100% {
        box-shadow: 0 0 5px #0f0;
    }
}

.drive-up {
    color: #11e041;
    /* Green */
}

.drive-down {
    color: #dc3545;
    /* Red */
}

.virtue-okay {
    background-color: #88b366;
    /* yellow-green */
}

.virtue-full {
    background-color: #33cc99;
    /* minty blue-green */
}

.story-entry {
    animation: fadeIn 0.5s ease-in-out;
    white-space: pre-wrap;
    padding: 4px 6px;
    border-radius: 4px;
    margin-bottom: 4px;
}

.story-entry.log-event {
    background-color: #1e1d23;
}

.story-entry.log-event-result {
    background-color: #221c21;
}

.story-entry.log-drive {
    background-color: #1c221c;
}

.story-entry.log-milestone {
    background-color: #1f1c23;
}

.story-entry.log-travel {
    background-color: #1c2124;
}

.story-entry.log-item {
    background-color: #242018;
}

.story-entry.log-death {
    background-color: #3b1c1c;
    color: #ffd1d1;
}

.story-entry.log-lore {
    background-color: #1a1f28;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.death-divider {
    text-align: center;
    color: #aa0000;
    font-size: 1.1em;
    margin: 0.5em 0;
}

.death-text {
    color: #ff0000;
    font-variant: small-caps;
    text-align: center;
    margin-bottom: 0.5em;
}

button.disabled {
    opacity: 0.3;
    pointer-events: none;
}

body.fadeout {
    animation: fadeToBlack 1s ease-in-out;
}

@keyframes fadeToBlack {
    0% {
        background-color: #121212;
        opacity: 1;
    }

    50% {
        background-color: #000000;
        opacity: 0;
    }

    100% {
        background-color: #121212;
        opacity: 1;
    }
}

/* Page grayscale effect on death */
.grayscale {
    filter: grayscale(100%);
}

/* Highlighted button */
button.highlight {
    background-color: #2e8b57;
    border-color: #66ff99;
    color: #fff;
    font-weight: bold;
    animation: pulse 1s infinite;
}

/* Pulsing glow */
.pulsing {
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 5px #0f0;
    }

    50% {
        box-shadow: 0 0 20px #0f0;
    }

    100% {
        box-shadow: 0 0 5px #0f0;
    }
}

/* Mappy CSS */
#mappy-container {
    width: 100%;
    height: auto;
    /* margin: 30px auto; */
    border: 3px solid #4c4c6d;
    border-radius: 12px;
    box-shadow: 0 0 15px #000;
    overflow: hidden;
}

#mappy {
    background-color: #2b2b40;
    /* Midnight blue map bg */
    width: 100%;
    height: auto;
    display: block;
}

#terrain rect {
    stroke: #2b2b40;
    stroke-width: 0.5;
    pointer-events: none;
}

.place {
    fill: #ff8fa3;
    /* Soft pink */
    stroke: #ffcfe1;
    stroke-width: 2px;
    cursor: pointer;
    transition: fill 0.2s ease, r 0.2s ease;
}

.place:hover {
    fill: #ffcfe1;
    r: 12;
}

.label {
    font-family: 'Trebuchet MS', sans-serif;
    font-size: 12px;
    text-anchor: middle;
    fill: #e0e0ff;
    pointer-events: none;
    user-select: none;
}

#inventoryDisplay {
    text-align: left;
    justify-content: left;
    align-items: left;
}

.inventory-item {
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid #e0e0e0;
}

.inventory-desc {
    font-size: 0.8em;
    color: #555;
}

.inventory-btn {
    background: none;
    border: none;
    font-size: 1.5em;
    cursor: pointer;
    padding: 0.25em 0.6em 0.25em 0;
    margin: 0;
    line-height: 1.2;
    min-width: 48px;
    /* For clickability */
    min-height: 48px;
    vertical-align: top;
    color: inherit;
}

.inventory-btn:focus {
    outline: 2px solid #6fa7ff;
}

.eventContainer {
    background: #191219;
    border-radius: 9px;
    box-shadow: 0 2px 12px #0008;
    padding: 1.1em 1.3em 1.2em 1.3em;
    margin: 1.5em auto;
    width: 95%;
    /* max-width: 600px; */
    text-align: left;
}

.eventPrompt {
    margin: 0 0 0.9em 0 !important;
    padding: 0 !important;
    text-indent: 0 !important;
    font-size: 1.07em !important;
    text-align: left !important;
    font-family: inherit;
    color: #ffd1ff;
    letter-spacing: 0.03em;
    line-height: 1.38;
}

.eventPrompt .eventAge,
.eventPrompt b {
    font-weight: 600;
    color: #bbb2ff;
    margin-right: 0.5em;
    font-size: 0.92em;
}

.choiceBtnContainer {
    display: flex;
    flex-direction: row;
    gap: 0.75em;
    justify-content: flex-start;
    margin: 0.3em 0 0 0 !important;
    padding: 0 !important;
}

.choiceBtn {
    min-width: 96px !important;
    max-width: 210px !important;
    font-size: 0.97em !important;
    padding: 0.37em 0.9em !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    border-radius: 7px !important;
    background: #322139;
    color: #ffedfa;
    border: 1px solid #a089a0;
    font-family: inherit;
    transition: background 0.18s, color 0.18s, box-shadow 0.2s;
    box-shadow: 0 1px 6px #1a001166;
    outline: none;
}

.choiceBtn:hover:enabled {
    background: #413158;
    color: #fff7ff;
    border-color: #fff;
    box-shadow: 0 0 10px #ffd1ff88;
}

.choiceBtn:disabled {
    opacity: 0.48;
    cursor: not-allowed;
}

@media (max-width: 600px) {
    .eventContainer {
        padding: 1em 0.5em 1.1em 0.5em;
        max-width: 99vw;
    }

    .choiceBtn {
        min-width: 70px !important;
        font-size: 0.95em !important;
    }
}

.event-result-description {
    color: #ffc3ee;
    font-style: italic;
    margin: 0.8em 0 0 0;
    padding: 0;
    font-size: 1em;
    letter-spacing: 0.01em;
    text-align: left;
}

.fineprint {
    font-size: 0.6em;
    color: #bbbbbb;
}

.audio-row {
    display: flex;
    align-items: center;
    margin-bottom: 14px;
    gap: 12px;
}

.audio-row label {
    width: 60px;
    color: #cc4aff;
    font-weight: bold;
    font-size: 1.1em;
}

.audio-row input[type="range"] {
    flex: 1;
    accent-color: #06e624;
    background: #333;
    height: 4px;
    border-radius: 2px;
}

.audio-row button {
    background: #222;
    border: 1px solid #ffe066;
    color: #ffe066;
    border-radius: 6px;
    cursor: pointer;
    padding: 3px 10px;
    font-size: 1em;
    box-shadow: 0 0 6px #ffe06688;
}

.audio-row button:hover {
    background: #333;
    border-color: #cc4aff;
    color: #cc4aff;
    box-shadow: 0 0 8px #cc4aff88;
}

@media screen and (max-width: 768px) {
    .rel-row {
        padding: 0.2em;
        margin: 0.3em auto;
        width: 96%;
    }

    .rel-mainline {
        gap: 0.6em;
        font-size: 1em;
    }

    .rels-bar-label {
        font-size: 10px;
        line-height: 1.2em;
        padding: 0 4px;
    }

    .bar-container,
    .rel-bar-wrap {
        width: 96%;
        max-width: 100%;
    }
}

/* ---------- Fullscreen map layout ---------- */
body.map-mode #centerPanel {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
}

body.map-mode #tab-mappy {
    display: block;
    width: 100%;
    height: 100%;
}

body.map-mode #tab-mappy svg {
    width: 100%;
    height: 100%;
}


body.map-mode #tab-story {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    max-height: 40vh;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.8);
    padding: 1em;
    z-index: 900;
}

body.map-mode #leftPanel,
body.map-mode #rightPanel {
    position: fixed;
    top: 10%;
    bottom: 10%;
    width: 120px;
    max-width:150px;
    min-width: 100px;
    overflow-y: auto;
    background: transparent;
    z-index: 800;
}

body.map-mode #leftPanel {
    left: 0;
}

body.map-mode #rightPanel {
    right: 0;
}

body.map-mode #leftPanel .bar-container,
body.map-mode #rightPanel .bar-container {
    background: transparent;
}

body.map-mode>#header,
body.map-mode>#pageFooter {
    display: none;
}