:root {
    --item-width: 4.557vw;
    --tag-width: 2.604vw;
    --graphic-width: 8vw;
}

@media (max-width: 600px) {
    :root {
        --item-width: 32px;
        --tag-width: 16px;
    }

    .item-name {
        font-size: 1.2vw !important;
    }
}

.item-grid-container {
    scrollbar-width: 1vw;
    scrollbar-color: rgba(133, 154, 248, 0.5) rgba(0, 0, 0, 0.5);
    scrollbar-gutter: stable;
}

*:focus {
    outline: none;
}

body {
    color: white;
    margin: 0;
    font-family: 'Inter';
    height: 90vh; 
    width: 100vw;
    background-color: black;
    background-image: none;
    background-size: cover;
}

.layout-container {
    margin: 1.5vh 0.705vw;
    position: relative;
    /* background-color: blue; */
}

.layout {
    display: grid;
    /* border: 1px solid yellow; */
    margin: 5vh auto; /*top bottom and sides*/
    max-width: 78.125vw;
    max-height: 90vh;
    grid-template-columns: 20% 80%;
    grid-template-rows: max-content max-content max-content 1fr;
}

.tag-title {
    grid-row: 1 / 2;
    grid-column: 1 / 2;
    background-color: purple;
}

.tag-grid-container {
    grid-row: 2 / 3;
    grid-column: 1 / 2;
}

.tag-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(var(--tag-width), 1fr));
    gap: 0.521vw;
    margin-right: 1.5vh;
}

.tag-unselected {
    display: grid;
    margin: auto;
    cursor: pointer;
    transition: 0.2s ease;
    opacity: 0.35;
}
    .tag-unselected img {
        width: 100%;
        height: auto;
    }
    .tag-unselected:hover {
        transform: scale(1.2);
    }
    .tag-unselected:focus-visible {
        outline: white solid 0.151vh;
    }
    .tag-unselected:focus-visible {
        transform: scale(1.2);

    }

.tag-selected {
    display: grid;
    margin: auto;
    cursor: pointer;
    transition: 0.2s ease;
    opacity: 1;
}
    .tag-selected img {
        width: 100%;    
        height: auto;
    }
    .tag-selected:hover {
        transform: scale(1.2);
    }
    .tag-selected:focus-visible {
        outline: white solid 0.151vh;
    }
    .tag-selected:focus-visible {
        transform: scale(1.2);
    }
    
.item-grid-container {
    grid-row: 1 / 5;
    grid-column: 2 / 3;
    overflow-y: auto;
    border-left: white 0.151vh dotted;
    overflow-x: hidden;
    /* padding-top: 3px;
    padding-bottom: 3px; */
}

.item-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(var(--item-width), 1fr));
    gap: 0.521vw;
    margin: 0px 1.5vh;
}

.item {
    font-size: 0; /*to remove space between img and txt elements*/
    border: rgba(255, 255, 255, 0.25) 0.151vh solid;
}
    .item img {
        width: 100%;
        height: auto; 
    }

    .item:focus {
        /* filter: brightness(1.2); */
        background-color: rgba(112, 248, 193, 0.7);
        anchor-name: --hovered-item;
    }

    .item:hover {
        /* filter: brightness(1.2); */
        background-color: rgba(112, 248, 193, 0.7);
        anchor-name: --hovered-item;
    }

.item-dim {
    font-size: 0;
    filter: brightness(0.65);
    border: rgba(255, 255, 255, 0.25) 0.151vh solid;
}
    .item-dim img {
        width: 100%;
        height: auto; 
    }

.item-name {
    display: grid;
    grid-template-columns: minmax(var(--item-width), 1fr);      /* must match .item-grid template columns to cetner text */
    grid-template-rows: calc(var(--item-width)*0.6);
    font-size: 0.781vw;
    text-align: center;
    align-items: center;
    justify-items: center;
    color: white;
    background-color: rgba(0, 0, 0, 0.5);
    border-top: rgba(255, 255, 255, 0.25) 0.151vh dashed;
    font-family: ms pgothic;
}

.nav-container {
    display: grid;
    position: absolute;
    color: white;
    font-size: 1.302vw;
    margin-right: 0.705vw;
    padding-left: 0.705vw;
    border-left: white 0.151vh dotted;
}   
    

.home:focus:not(:focus-visible), .about:focus:not(:focus-visible), .images:focus:not(:focus-visible), .icons:focus:not(:focus-visible), .toggle-background:focus:not(:focus-visible) {
    opacity: 0.5;
}
.home:focus:not(:focus-visible):hover, .about:focus:not(:focus-visible):hover, .images:focus:not(:focus-visible):hover, .icons:focus:not(:focus-visible):hover, .toggle-background:focus:not(:focus-visible):hover {
    opacity: 1;
}

.home {
    grid-row: 1 / 2;
    grid-column: 1 / 2;
    cursor: pointer;
    opacity: 0.5;
}
    .home:focus {
        opacity: 1;
    }
    .home:hover {
        opacity: 1;
    }

.about {
    grid-row: 2 / 3;
    grid-column: 1 / 2;
    cursor: pointer;
    opacity: 0.5;
}
    .about:focus {
        opacity: 1;
    }
    .about:hover {
        opacity: 1;
    }

.images {
    grid-row: 3 / 4;
    grid-column: 1 / 2;
    cursor: pointer;
    opacity: 0.5;
}
    .images:focus {
        opacity: 1;
    }
    .images:hover {
        opacity: 1;
    }

.icons {
    grid-row: 4 / 5;
    grid-column: 1 / 2;
    cursor: pointer;
    opacity: 0.5;
}
    .icons:focus {
        opacity: 1;
    }
    .icons:hover {
        opacity: 1;
    }

.toggle-background {
    grid-row: 5 / 6;
    grid-column: 1 / 2;
    cursor: pointer;
    opacity: 0.5;
}
    .toggle-background:focus {
        opacity: 1;
    }
    .toggle-background:hover {
        opacity: 1;
    }

.search-title {
    border-left: white 0.151vh dotted;
    grid-row: 1 / 2;
    grid-column: 1 / 2;
    padding-left: 0.705vw;
    font-size: 1.432vw;
    display: grid;
    grid-template-columns: 80% 20%;
    margin-right: 0.705vw;
}
    .search-title h2 {
        grid-column: 1 / 2;
        font-size: 1.432vw;
        margin-bottom: 0px;
        margin-top: 0px;
    }

    .search-title .info {
        grid-column: 2 / 3;
        /* display: inline-block; */
        /* height: 3vh;
        width: 3vh; */
        display: grid;

        /* object-fit: cover; */
        /* justify-items: center;
        align-items: center; */
        width: 70%;
        margin: auto;
    }

    .search-title .info:hover, .search-title .info:focus {
        filter: brightness(0.75);
    }

.search-container {
    /* border-left: white 1px dotted; */
    grid-row: 2 / 3;
    grid-column: 1 / 2;
    overflow: hidden;
    margin-right: 0.705vw;
    margin-top: 0.5vh;
}
    .search-container input {
        display: block;
        border-radius: 0;
        border: rgba(255, 255, 255, 0.25) solid 0.151vh;
        background-color: rgba(255, 255, 255, 0.1);
        margin-bottom: 0.5vh;
        box-sizing: border-box;
        width: 100%;
        color: white;
        font-size: 0.781vw;
    }

    .search-container input:focus {
        border: rgba(133, 154, 248, 1) solid 0.151vh;
    }

    .search-container button {
        display: block;
        /* margin: 0; */
        border-radius: 0;
        font-family: ms pgothic;
        font-weight: bold;
        filter: brightness(0.75);
        border: 0.302vh outset rgb(153, 153, 162);
        font-size: 0.781vw;
        width: max-content;
    }

    .search-container button:focus {
        filter: brightness(1.25);
    }
    .search-container button:hover {
        filter: brightness(1.25);
    }
    .search-container button:focus:not(:focus-visible) {
        filter: brightness(0.75);
    }
    .search-container button:focus:not(:focus-visible):hover {
        filter: brightness(1.25);
    }

.about-content {
    color: white;
    grid-row: 1 / 5;
    grid-column: 1 / 3;
    font-family: ms pgothic;
}
    .about-content p {
        margin: 0;
        margin-bottom: 3vh;
        font-size: 1vw;
        text-shadow:
            0.151vh 0 0.26vw black,
            0 0.151vh 0.26vw black,
            -0.151vh 0 0.26vw black,
            0 -0.151vh 0.26vw black;
    }
    .about-content a {
        color: rgba(133, 154, 248);
    }
    .about-content a:focus, .about-content a:hover {
        filter: brightness(2);
    }

.player {
    display: grid;
    width: max-content;
    margin-top: 0.5vh;
}
    .player:focus .play-button {
        background-color: rgba(255, 255, 255, 0.5);
    }
    .player:hover .play-button {
        background-color: rgba(255, 255, 255, 0.5);
    }
    .player:focus:not(:focus-visible) .play-button {
        background-color: rgba(255, 255, 255, 0.25);
    }
    .player:focus:not(:focus-visible):hover .play-button {
        background-color: rgba(255, 255, 255, 0.5);
    }

.play-button {
    background-color: rgba(255, 255, 255, 0.25);
    border-radius: 0.26vw;
    padding: 10%;
    width: 3vw;
    height: clamp(1.302vw,1vw,2.604vw);
    margin-bottom: 0.5vh;
    cursor: pointer;
}

.graphic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(var(--graphic-width), 1fr));
    gap: 0.521vw;
    margin: 0px 0.705vw;
}
    .graphic-grid a {
        display: grid;
    }
    .graphic-grid a:focus {
        display: grid;
        /* outline: auto; */
        background-color: rgba(133, 154, 248, 0.6);
    }


.graphic {
    height: 7.813vw;
    width: 100%;
    object-fit: contain;
    overflow: hidden;
    background-color: rgba(133, 154, 248, 0.25);
    /* background-image: url("https://assets-bucket.deadlock-api.com/assets-api-res/images/main_menu/play/card_brawl.png"); */
}
    .graphic:focus {
        background-color: rgba(133, 154, 248, 0.6);
        /* background-image: url("https://assets-bucket.deadlock-api.com/assets-api-res/images/shop/dmg_report_texture.png"); */
        background-size: cover;
        /* outline: auto; */
        
    }
    .graphic:hover {
        background-color: rgba(133, 154, 248, 0.6);
        /* background-image: url("https://assets-bucket.deadlock-api.com/assets-api-res/images/shop/dmg_report_texture.png"); */
        background-size: cover;
        /* outline: auto; */
    }

/* .tooltip-container {
    outline: rgba(112, 248, 193, 0.7) 1px solid;
    margin: 10px;
} */

.tooltip-container {
    visibility: hidden;
    margin-left: 0.5vw;
    font-family: ms pgothic;
    font-size: 1.042vw;
    width: 26.042vw;
    /* margin: 0;
    inset: auto; */
    background-color: rgb(0, 0, 0);
    position: absolute;
    position-anchor: --hovered-item;
    outline: rgba(112, 248, 193, 0.7) 0.151vh solid;
    position-area: right span-bottom;
    
    position-try: none;

    z-index: 1000;
}

.tooltip {
    margin: 0.26vw;
}

.tooltip-component-container:not(:empty) {
    display: grid;
    gap: 0.151vh;
    background-color: black;
    border-top: rgba(255, 255, 255, 0.5) 0.151vh dashed;
}

.tooltip-img {
    /* background-color: rgb(0, 84, 92); */
    display: grid;
    grid-template-columns: 2.083vw 1fr;
    gap: 0.651vw;
    vertical-align: middle;
    
}
    .tooltip-img img {
        width: 100%;
        height: auto;
    }

.header-img {
    /* background-color: rgb(0, 84, 92); */
    display: grid;
    grid-template-columns: 1.563vw 1fr;
    
}
    .header-img img {
        width: 100%;
        height: auto;
    }

.component-text {
    display: grid;
    /* text-align: center; */
    align-items: center;
    /* justify-items: center; */
}

.tooltip-header {
    background-color: black;
    display: grid;
    grid-template-columns: 1fr max-content;
    /* border-bottom: rgba(255, 255, 255, 0.5) 1px dashed; */
}

.tooltip-item-name {
    font-weight: bold;
}

.tooltip-sections {
    background-color: rgb(0, 0, 0);
    /* border-bottom: rgba(255, 255, 255, 0.5) 1px dashed; */
}

    .tooltip-sections img {
        height: 1.3vw;
        width: auto;
        margin-right: 0.195vw;
        vertical-align: -0.195vw;
        /* padding: 0.vw; */
        
    }

.tooltip-footer {
    background-color: rgb(0, 0, 0);
    
}

.section-header {
    display: grid;
    grid-template-columns: 1fr max-content;
    border-top: rgba(255, 255, 255, 0.5) 0.151vh dashed;
    border-bottom: rgba(255, 255, 255, 0.5) 0.151vh dashed;
    margin-top: 0.2vw;
    /* margin-bottom: 0.2vw; */
    padding-top: 0.1vw;
    padding-bottom: 0.1vw;
}

    .section-header img {
        margin-right: 0.326vw; 
    }

.highlight {
    font-weight: bold;
    text-shadow:
        0.151vh 0 0.26vw rgba(255, 255, 255, 0.15),
        0 0.151vh 0.26vw rgba(255, 255, 255, 0.15),
        -0.151vh 0 0.26vw rgba(255, 255, 255, 0.15),
        0 -0.151vh 0.26vw rgba(255, 255, 255, 0.15);
    /* color: white !important; */
}


.inline-attribute-label.BonusWeaponDamage, .inline-attribute-label.WeaponDamage, .inline-attribute-label.BonusFireRate, .inline-attribute-label.FireRate {
    color: #ec9719;
    text-shadow: none !important;
}

.inline-attribute-label.Heal, .inline-attribute-label.BonusMoveSpeed, .inline-attribute-label.BonusSprintSpeed, .inline-attribute-label.MoveSpeed {
    color: #0F9;
    text-shadow: none !important;
}

.inline-attribute-label.BonusSpiritDamage, .inline-attribute-label.SpiritDamage {
    color: #ce90ff;
    text-shadow: none !important;
}

.diminish {
    font-style: italic;
    color: rgba(255, 255, 255, 0.25);
}

.scaling-items {
    position: absolute;
    transform: translate(0px, -0.651vw);
    top: 0;
    right: 0;
    font-size: 0.781vw;
    text-shadow:
        0.151vh 0 0.26vw black,
        0 0.151vh 0.26vw black,
        -0.151vh 0 0.26vw black,
        0 -0.151vh 0.26vw black;
}

    .scaling-items img {
        margin-right: 0px;
        width: 1.823vw;
        height: auto;
        position: relative;
        transform: translate(0px, 0.781vw);
        z-index: -5;

    }

.conditional {
    font-style: italic;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8vw;
}

.negative-attribute {
    color: red;
}

.flex-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.36vw;
    margin-top: 0.26vw;
    margin-bottom: 0.26vw;
}

.flex-item {
    flex-grow: 1;
    display: flex;
    text-align: center;
    align-items: center;
    justify-content: space-around;
    background-color: #000000;
    background-image: radial-gradient(circle, rgba(255, 255, 255, 0.15) 1px, transparent 1px);
    background-size: 6px 6px;
    background-position: 0 0;
    background-repeat: repeat;
    border: rgba(255, 255, 255, 0.35) 0.151vh dashed;
    /* vertical-align: middle; */
    padding: 0.521vw;
    position: relative; /* necessary for absolute stat_scale */
    /* margin: auto; */
}
    .flex-item img {
        margin-right: 0.326vw;     
    }

.flex-item:nth-child(1) {    flex-basis: 26%; }
.flex-item:nth-child(2) {    flex-basis: 26%; }
.flex-item:nth-child(3) {    flex-basis: 26%; }
.flex-item:nth-child(4)   {  flex-basis: 40%; }

.flex-item:has(+ .flex-item:nth-child(4)) {
    flex-basis: 40%;
}

.flex-item-bottom {
    flex-grow: 1;
    flex-basis: 55%;
    /* display: flex; */
    text-align: left;
    font-size: 0.9vw;
    /* vertical-align: middle; */
    padding: 0.521vw;
    position: relative; /* necessary for absolute stat_scale */
    background-color: #000000;
    background-image: radial-gradient(circle, rgba(255, 255, 255, 0.15) 1px, transparent 1px);
    background-size: 6px 6px;
    background-position: 0 0;
    background-repeat: repeat;
    border: rgba(255, 255, 255, 0.35) 0.151vh dashed;
    
}
    .flex-item-bottom img {
        margin-right: 0.326vw;     
    }

.flex-item:nth-child(2) ~ .flex-item-bottom {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(49%, 1fr));
}

/* .important-label {
    min-width: fit-content;
} */