:root {
    --balloon: polygon(49% 3%, 56% 15%, 66% 3%, 66% 18%, 82% 6%, 75% 18%, 92% 13%, 79% 30%, 95% 32%, 82% 43%, 95% 48%, 76% 55%, 94% 70%, 75% 70%, 79% 86%, 65% 75%, 60% 87%, 49% 74%, 34% 95%, 36% 68%, 18% 75%, 24% 60%, 4% 63%, 19% 49%, 8% 44%, 21% 38%, 7% 26%, 24% 29%, 13% 11%, 33% 21%, 29% 5%, 41% 16%);
}

.black_outlined {
    position: relative;
    display: block;
    width: fit-content;
    height: fit-content;
    color: var(--white);
}

.black_outlined::after {
    content: attr(data);
    position: absolute;
    top: 0;
    left: 0;

    color: var(--white);
    -webkit-text-fill-color: var(--black);
    -webkit-text-stroke: 8px var(--black);
    z-index: -1;
}

/*************************************************************
******************** Heroes_headquarters **********************
*************************************************************/

#Heroes_headquarters {
    min-height: calc(100dvh - 40px);
    overflow: hidden;
    position: relative;
    padding-bottom: 50px;

    background-image: url("../assets/images/headquarters/bg_v_headquarter.jpg");
    background-position: right top;
    background-size: cover;
}

#Heroes_headquarters .bg::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    background-repeat: repeat;
    background-color: #00335544;
    background-image:
        radial-gradient(#000000FF 25%, transparent 25%);
    background-size: 4px 4px;

    z-index: 0;
}

.bg_balloons {
    z-index: 1;
    position: absolute;

    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    overflow: hidden;
    cursor: unset;
    pointer-events: none;
}

.bg_balloons .balloon {
    position: absolute;
    clip-path: var(--balloon);
    background-color: #000000;
}

.bg_balloons .balloon::after {
    content: "";
    position: absolute;

    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);

    width: 85%;
    height: 85%;

    clip-path: var(--balloon);
    background-color: var(--white);

    background-repeat: repeat;
    background-image:
        radial-gradient(#000 15%, transparent 15%),
        radial-gradient(#000 15%, transparent 15%);

    background-size: 12px 12px;
    background-position: 0 0, 6px 6px;
}

#Heroes_headquarters .bg_balloons .balloon.balloon1 {
    width: 400px;
    height: 400px;
    right: -100px;
    top: -150px;
}

/***********title***********/

#Heroes_headquarters .content.title {
    position: relative;
    width: 100%;
    padding: 9px;
    border: 5px solid black;
    border-bottom-width: 10px;
    background-color: var(--white);
    z-index: 2;
}

#Heroes_headquarters .content.title::before,
#Heroes_headquarters .content.title::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    background-size: contain;
}

#Heroes_headquarters .content.title::before {
    background-image: url(../../assets/images/warpLeft.png);
    background-position: left;
}

#Heroes_headquarters .content.title::after {
    background-image: url(../../assets/images/warpRight.png);
    background-position: right;
}

#Heroes_headquarters h2 {
    display: flex;
    align-items: center;
    justify-content: center;
}

#Heroes_headquarters h2 img {
    height: 64px;
    width: auto;
}

#Heroes_headquarters h2::after {
    display: inline-block;
    content: attr(data);
    font-size: 12px;
    color: var(--black);
    margin: auto 6px;
}

#Heroes_headquarters .container {
    padding-top: 40px;
    position: relative;
    z-index: 2;
}

@media (max-width:992px) {
    html {
        overflow-x: auto;
    }

    #Heroes_headquarters h2 {
        display: block;
        margin: auto;
    }

    #Heroes_headquarters h2 img {
        margin: auto;
        height: auto;
        max-height: 40px;
    }

    #Heroes_headquarters h2::after {
        display: block;
        font-size: 12px;
        margin: auto;
    }
}

/***********description***********/

#Heroes_headquarters .wrapper.description {
    padding-top: 32px;
}

#Heroes_headquarters .wrapper.description h1 {
    font-size: 32px;
    width: 35%;
    text-align: left;
    color: var(--white);
    position: relative;
}

#Heroes_headquarters .wrapper.description .tour_logo {
    height: 84px;
}

#Heroes_headquarters .wrapper.description p {
    width: 65%;
    text-align: left;
    color: var(--white);
    position: relative;
}

@media (max-width:992px) {
    #Heroes_headquarters .wrapper.description {
        display: block;
    }

    #Heroes_headquarters .wrapper.description h1 {
        width: 100%;
    }

    #Heroes_headquarters .wrapper.description .tour_logo {
        height: 120px;
        width: fit-content;
        margin: 0 auto 32px auto;
        display: block;
    }

    #Heroes_headquarters .wrapper.description p {
        width: 100%;
    }
}

/***********headquarter_view***********/

.headquarter_view {
    position: relative;

    width: 100%;
    aspect-ratio: 1181/1061;
    margin-top: 32px;

    background: url("../assets/images/headquarters/headquarters.png");
    background-size: 80%;
    background-position: center;
    background-repeat: no-repeat;

    z-index: inherit;
}

.headquarter_view .dot {
    position: absolute;
    z-index: -1;

    width: 10px;
    height: 10px;

    border-radius: 50%;
    background-color: var(--black);
}

.headquarter_view .room_button:hover~.dot::before {
    position: absolute;
    content: "";
    display: inline-block;

    top: 0;
    left: -10%;
    width: 120%;
    height: auto;

    aspect-ratio: 1/1;
    border: 1px solid var(--yellow);
    border-radius: 100%;
    animation: circleBorder 1s infinite;
}

@keyframes circleBorder {
    0% {
        opacity: 1;
        transform: scale(1, 1);
    }

    100% {
        opacity: 0;
        transform: scale(5, 5);
    }
}

.headquarter_view .horizontal_line {
    position: absolute;
    z-index: -1;
    border: 1px solid var(--black);
}

.headquarter_view .vertical_line {
    position: absolute;
    z-index: -1;
    border: 1px solid var(--black);
}

.headquarter_view .room_button:hover~div {
    border-color: var(--yellow);
    background-color: var(--yellow);
}

.headquarter_view .T.L .dot {
    transform: translate(-50%, -50%);
}

.headquarter_view .B.L .dot {
    transform: translate(-50%, 50%);
}

.headquarter_view .T.R .dot {
    transform: translate(50%, -50%);
}

.headquarter_view .B.R .dot {
    transform: translate(50%, 50%);
}

.headquarter_view .T .horizontal_line {
    transform: translate(0, -50%);
}

.headquarter_view .B .horizontal_line {
    transform: translate(0, 50%);
}

.headquarter_view .L .vertical_line {
    transform: translate(-50%, 0);
}

.headquarter_view .R .vertical_line {
    transform: translate(50%, 0);
}


.headquarter_view .room_button_wrapper {
    position: absolute;
    pointer-events: none;
    cursor: unset;

    top: 0;
    bottom: 0;
    left: 0;
    right: 0;

    z-index: 2;
}

.headquarter_view .room_button {
    position: absolute;
    overflow: hidden;
    font-weight: bold;
    text-wrap: wrap;
    cursor: pointer;
    pointer-events: all;

    padding: 8px;
    width: 35%;

    border: 5px solid var(--black);
    box-shadow: 5px 5px 0 0 var(--black);

    z-index: 2;
}

.headquarter_view .room_button .bg_balloon {
    position: absolute;

    left: 30%;
    right: 30%;
    top: 0;
    transform: translateY(-30%);
    aspect-ratio: 1/1;

    background-color: #dddddd;
    clip-path: var(--balloon);

    z-index: -1;
}

.headquarter_view .room_button .bg_balloon::before {
    content: "";
    position: absolute;

    left: 10%;
    right: 10%;
    top: 50%;
    transform: translateY(-50%);
    aspect-ratio: 1/1;

    background-color: var(--white);
    clip-path: var(--balloon);

    z-index: 1;
}

.headquarter_view .L .room_button {
    left: 0;
}

.headquarter_view .R .room_button {
    right: 0;
}

.headquarter_view .room_button span {
    margin: auto;
    z-index: 3;
}

.headquarter_view .room_button::before {
    content: "";
    position: absolute;

    left: 0;
    right: 0;
    top: 0;
    bottom: 0;

    background-color: var(--white);
    background-repeat: repeat;
    background-image:
        radial-gradient(#00000033 25%, transparent 25%),
        radial-gradient(#00000033 25%, transparent 25%);
    background-size: 8px 8px;
    background-position: 0 0, 4px 4px;

    z-index: -1;
}

.headquarter_view .room_button:hover:before {
    background-color: var(--yellow);
}

.headquarter_view .room_button::after {
    text-shadow: 0 4px 0 var(--black);
}

@media(max-width:992px) {
    .headquarter_view .room_button .bg_balloon {
        right: -20%;
        left: 70%;
    }

}

/*H-13*/
.headquarter_view .wrapper_H-13 .dot {
    top: 25%;
    left: 47%;
}

.headquarter_view .wrapper_H-13 .horizontal_line {
    top: 13%;
    left: 10%;
    right: 53%;
}

.headquarter_view .wrapper_H-13 .vertical_line {
    top: 13%;
    bottom: 75%;
    left: 47%;
}

.headquarter_view .room_button.H-13 {
    top: 10%;
}

@media(max-width:992px) {

    .headquarter_view .wrapper_H-13 .horizontal_line {
        top: 5%;
    }

    .headquarter_view .wrapper_H-13 .vertical_line {
        top: 5%;
    }

    .headquarter_view .room_button.H-13 {
        top: 0%;
    }
}

/*H-10*/
.headquarter_view .wrapper_H-10 .dot {
    top: 30%;
    left: 46%;
}

.headquarter_view .wrapper_H-10 .horizontal_line {
    top: 23%;
    left: 10%;
    right: 54%;
}

.headquarter_view .wrapper_H-10 .vertical_line {
    top: 23%;
    bottom: 70%;
    left: 46%;
}

.headquarter_view .room_button.H-10 {
    top: 20%;
}

@media(max-width:992px) {

    .headquarter_view .wrapper_H-10 .horizontal_line {
        top: 20%;
    }

    .headquarter_view .wrapper_H-10 .vertical_line {
        top: 20%;
    }

    .headquarter_view .room_button.H-10 {
        top: 15%;
    }
}

/*T1-RF*/
.headquarter_view .wrapper_T1-RF .dot {
    top: 40%;
    left: 37%;
}

.headquarter_view .wrapper_T1-RF .horizontal_line {
    top: 33%;
    left: 10%;
    right: 63%;
}

.headquarter_view .wrapper_T1-RF .vertical_line {
    top: 33%;
    bottom: 60%;
    left: 37%;
}

.headquarter_view .room_button.T1-RF {
    top: 30%;
}

/*T1-2F*/
.headquarter_view .wrapper_T1-2F .dot {
    bottom: 48%;
    left: 31%;
}

.headquarter_view .wrapper_T1-2F .horizontal_line {
    bottom: 48%;
    left: 10%;
    right: 69%;
}

.headquarter_view .wrapper_T1-2F .vertical_line {
    top: 52%;
    bottom: 33%;
    left: 10%;
}

.headquarter_view .room_button.T1-2F {
    bottom: 30%;
    width: fit-content;
}

@media(max-width:992px) {

    .headquarter_view .wrapper_T1-2F .vertical_line {
        bottom: 40%;
    }

    .headquarter_view .room_button.T1-2F {
        bottom: 35%;
    }
}

/*T1-1F*/
.headquarter_view .wrapper_T1-1F .dot {
    bottom: 43%;
    left: 32%;
}

.headquarter_view .wrapper_T1-1F .horizontal_line {
    bottom: 20%;
    left: 23%;
    right: 68%;
}

.headquarter_view .wrapper_T1-1F .vertical_line {
    top: 57%;
    bottom: 23%;
    left: 32%;
}

.headquarter_view .room_button.T1-1F {
    bottom: 20%;
}

/*H-15*/
.headquarter_view .wrapper_H-15 .dot {
    top: 17%;
    right: 49%;
}

.headquarter_view .wrapper_H-15 .horizontal_line {
    top: 13%;
    left: 51%;
    right: 20%;
}

.headquarter_view .wrapper_H-15 .vertical_line {
    top: 13%;
    bottom: 83%;
    right: 49%;
}

.headquarter_view .room_button.H-15 {
    top: 10%;
}

@media(max-width:992px) {

    .headquarter_view .wrapper_H-15 .horizontal_line {
        top: 5%;
    }

    .headquarter_view .wrapper_H-15 .vertical_line {
        top: 5%;
    }

    .headquarter_view .room_button.H-15 {
        top: 0%;
    }
}

/*H-14*/
.headquarter_view .wrapper_H-14 .dot {
    top: 21.5%;
    right: 51%;
}

.headquarter_view .wrapper_H-14 .horizontal_line {
    top: 23%;
    left: 49%;
    right: 20%;
}

.headquarter_view .wrapper_H-14 .vertical_line {
    top: 21.5%;
    bottom: 77%;
    right: 51%;
}

.headquarter_view .room_button.H-14 {
    top: 20%;
}

@media(max-width:992px) {

    .headquarter_view .wrapper_H-14 .horizontal_line {
        top: 20%;
    }

    .headquarter_view .wrapper_H-14 .vertical_line {
        top: 20%;
        bottom: 79%;
    }

    .headquarter_view .room_button.H-14 {
        top: 15%;
    }
}

/*H-8*/
.headquarter_view .wrapper_H-8 .dot {
    top: 31%;
    right: 52%;
}

.headquarter_view .wrapper_H-8 .horizontal_line {
    top: 33%;
    left: 48%;
    right: 20%;
}

.headquarter_view .wrapper_H-8 .vertical_line {
    top: 31%;
    bottom: 67%;
    right: 52%;
}

.headquarter_view .room_button.H-8 {
    top: 30%;
}

/*T2-5F*/
.headquarter_view .wrapper_T2-5F .dot {
    bottom: 59%;
    right: 42%;
}

.headquarter_view .wrapper_T2-5F .horizontal_line {
    bottom: 33%;
    left: 58%;
    right: 20%;
}

.headquarter_view .wrapper_T2-5F .vertical_line {
    top: 41%;
    bottom: 33%;
    right: 42%;
}

.headquarter_view .room_button.T2-5F {
    bottom: 30%;
}

@media(max-width:992px) {

    .headquarter_view .wrapper_T2-5F .horizontal_line {
        bottom: 40%;
    }

    .headquarter_view .wrapper_T2-5F .vertical_line {
        bottom: 40%;
    }

    .headquarter_view .room_button.T2-5F {
        bottom: 35%;
    }
}

/*H-1*/
.headquarter_view .wrapper_H-1 .dot {
    bottom: 37%;
    right: 50%;
}

.headquarter_view .wrapper_H-1 .horizontal_line {
    bottom: 23%;
    left: 50%;
    right: 20%;
}

.headquarter_view .wrapper_H-1 .vertical_line {
    top: 63%;
    bottom: 23%;
    right: 50%;
}

.headquarter_view .room_button.H-1 {
    bottom: 20%;
}


@media (max-width:768px) {
    .headquarter_view .dot {
        width: 5px;
        height: 5px;
    }

    .headquarter_view .black_outlined {
        font-size: 12px;
        line-height: 1.5em;
    }

    .black_outlined::after {
        -webkit-text-stroke: 4px var(--black);
    }

    .headquarter_view .room_button {
        padding: 2px;
        border: 2px solid var(--black);
        box-shadow: 2px 2px 0 0 var(--black);
    }

    .headquarter_view .room_button.T1-1F {
        bottom: 10%;
    }

    .headquarter_view .room_button.H-1 {
        bottom: 10%;
    }

    .headquarter_view .wrapper_T1-1F .horizontal_line {
        bottom: 13%;
    }

    .headquarter_view .wrapper_T1-1F .vertical_line {
        bottom: 13%;
    }

    .headquarter_view .wrapper_H-1 .horizontal_line {
        bottom: 13%;
    }

    .headquarter_view .wrapper_H-1 .vertical_line {
        bottom: 13%;
    }
}

@media (max-width:576px) {
    .headquarter_view .black_outlined {
        font-size: 8px;
        line-height: 1.5em;
    }
}

/****************************************
************** Modal_Window *************
****************************************/
.disabled {
    opacity: 0;
    cursor: unset;
    pointer-events: none;
}

#Heroes_headquarters .container {
    transition: opacity 500ms, transform 300ms;
}

#Heroes_headquarters .container.disabled {
    transform: scale(10);
}

#Modalwindow {
    position: fixed;
    display: flex;
    align-items: center;

    top: 0;
    right: 0;

    width: calc(100% - 180px);
    height: calc(100dvh - 40px);

    background-color: #00338844;
    transition: opacity 500ms;

    z-index: 5;
}

#Modalwindow .bg_balloons {
    overflow: visible;
}

#Modalwindow .bg_balloons .balloon.balloon1 {
    width: 400px;
    height: 400px;
    left: 0px;
    top: -150px;
}

#Modalwindow .bg_balloons .balloon.balloon2 {
    width: 250px;
    height: 250px;
    right: 15%;
    top: -50px;
}

#Modalwindow .bg_balloons .balloon.balloon3 {
    width: 500px;
    height: 500px;
    right: -100px;
    bottom: -200px;
}


#Modalwindow .container {
    max-width: 1200px;
    z-index: 2;
}

#Modalwindow .wrapper {
    justify-content: space-between;
}

#Modalwindow .container {
    width: 100%;
}

#Modalwindow button {
    position: absolute;

    width: 80px;
    height: 80px;

    top: 30px;
    right: 30px;

    border-radius: 50%;

    background-color: var(--yellow);
    border: 5px solid var(--black);

    z-index: 5;
}

#Modalwindow button::before,
#Modalwindow button::after {
    content: "";
    position: absolute;
    width: 50%;
    height: 0;
    border: 2px solid var(--black);
    top: 50%;
    left: 50%;
}

#Modalwindow button::before {
    transform: translate(-50%, -50%) rotate(-45deg);
}

#Modalwindow button::after {
    transform: translate(-50%, -50%) rotate(45deg);
}

#Modalwindow .modal_image img {
    width: 100%;
    height: auto;
}

#Modalwindow .modal_image .tour_logo {
    position: absolute;
    width: 20%;
    height: auto;
    left: 50%;
    top: 0;
    transform: translate(-50%, -50%);
}


#Modalwindow .text_box {
    position: relative;
    text-align: left;

    height: auto;

    color: white;
    width: 35%;
}

#Modalwindow .text_box .location {
    font-weight: bold;
    font-size: 2rem;
}

#Modalwindow .text_box h4 {
    white-space: pre;
    font-size: 4rem;
    line-height: 4rem;
}

#Modalwindow .text_box p {
    padding: 32px 80px 0 0;
}

#Modalwindow .text_box .character_image {
    position: absolute;
    left: 85%;
    top: 40%;
    bottom: -40%;
    width: auto;
    z-index: 2;
}


#Modalwindow .modal_image {
    position: relative;
    width: 60%;
}

#Modalwindow .modal_image #Modal_image {
    border: 10px solid var(--black);
}

@media(max-width:1400px) {

    #Modalwindow .text_box h4 {
        white-space: inherit;
        word-wrap: break-word;
    }
}

@media(max-width:992px) {
    #Modalwindow {
        top: 60px;
        right: 0;

        width: 100%;
        height: calc(100dvh - 60px);

        overflow-y: scroll;
        align-items: flex-start;

        padding-top: 40px;
    }

    #Modalwindow .bg_balloons .balloon.balloon1 {
        left: -100px;
        top: -200px
    }

    #Modalwindow .bg_balloons .balloon.balloon2 {
        width: 200px;
        height: 200px;
        right: 0%;
        top: 25%;
    }

    #Modalwindow .bg_balloons .balloon.balloon3 {
        width: 150px;
        height: 150px;
        right: -50px;
        bottom: -50px;
    }

    #Modalwindow button {
        position: absolute;

        width: 40px;
        height: 40px;

        top: 30px;
        right: 10px;

        border-radius: 50%;

        background-color: var(--yellow);
        border: 2px solid var(--black);

        z-index: 5;
    }

    #Modalwindow .wrapper {
        display: flex;
        flex-direction: column-reverse;
    }

    #Modalwindow .modal_image #Modal_image {
        border: 5px solid var(--black);
    }

    #Modalwindow .text_box {
        width: 100%;
        margin: auto;
    }

    #Modalwindow .text_box h4 {
        font-size: 2rem;
        line-height: 2rem;
    }

    #Modalwindow .text_box .location {
        font-size: 1.5rem;
    }

    #Modalwindow .modal_image {
        width: 100%;
        margin: auto;
    }

    #Modalwindow .location,
    #Modalwindow #Location_name,
    #Modalwindow #Description {
        padding-right: 40%;
        padding-top: 0;
    }

    #Modalwindow #Description {
        font-size: 0.8rem;
    }

    #Modalwindow .text_box .character_image {
        top: 0;
        bottom: auto;
        right: 0;
        left: 60%;
        height: 120%;
        text-align: right;
    }

    #Modalwindow .text_box .character_image img {
        max-height: 120%;
        margin: auto;
    }
}