body {
    background: #f0f0f0;
    margin: 0;
    overflow: hidden;
}

#riveCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

#model {
    height: 100%;
    width: auto;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-direction: row;
    padding: 25px 50px;
}

.header-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.header-logo > img {
    width: 120px;
}

.header-logo > div {
    color: white;
    font-size: 14px;
    margin-top: 5px;
}

.btn-trigger {
    position: relative;
    width: 30px;
    height: 23px;
    cursor: pointer;
}

.btn-trigger span {
    position: absolute;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: #fff;
    border-radius: 4px;
}

.btn-trigger, .btn-trigger span {
    display: inline-block;
    transition: all .5s;
    box-sizing: border-box;
}

.btn-trigger span:nth-of-type(1) {
    top: 0;
}

.btn-trigger span:nth-of-type(2) {
    top: 10px;
}

.btn-trigger span:nth-of-type(3) {
    bottom: 0;
}

#btn01.active span:nth-of-type(1) {
    -webkit-transform: translateY(10px) rotate(-45deg);
    transform: translateY(10px) rotate(-45deg);
}

#btn01.active span:nth-of-type(2) {
    opacity: 0;
}

#btn01.active span:nth-of-type(3) {
    -webkit-transform: translateY(-10px) rotate(45deg);
    transform: translateY(-10px) rotate(45deg);
}

.menu {
    display: none;
    position: fixed;
    top: 100px;
    right: 40px;
    width: 170px;
    height: 270px;
    background-color: #ffffff63;
    padding: 15px 25px;
    border-radius: 5px;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: flex-start;
    flex-wrap: wrap;
    font-weight: 300;
}

.menu > a {
    display: flex;
    flex-direction: row;
    align-items: center;
    color: white;
    font-size: 18px;
    text-decoration: none;
}

.menu > a:visited {
    color: white;
    text-decoration: none;
}

.menu > a:hover {
    font-weight: 500;
    font-size: 20px;
}

.menu > a > img {
    width: 15px;
    height: 15px;
    margin-right: 8px;
}

.tooltip {
    position: relative;
    display: inline-block;
    padding: 20px 40px;
    color: #fff;
    border-radius: 4px;
    background-color: #202a5a;
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    line-height: 1.5;
    letter-spacing: 1.5px;
    pointer-events: none;
    top: 100px;
    text-align: center;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
    transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    z-index: 10;
}

.tooltip::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    border-style: solid;
    border-width: 30px 20px 0 20px;
    border-color: #202a5a transparent transparent;
    translate: -50% 100%;
}

#loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999; /* 全部の上 */
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

#loading-overlay.hidden {
    opacity: 0;
    visibility: hidden;
}

#loading-image {
    max-width: 200px;
    width: 40%;
    height: auto;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}
.star {
    position: fixed;
    top: -15px;
    left: -15px;
    width: 15px;
    height: 15px;
    background: 50% 50% no-repeat;
    background-size: contain;
    z-index: 100;
    animation: star 2.5s ease-out 0s forwards;
    pointer-events: none;
}

@keyframes star {
    0% {
        transform: translateY(0) rotate(-5deg);
        opacity: 0;
    }

    5% {
        opacity: 1;
    }

    80% {
        opacity: 1;
    }

    100% {
        transform: translateY(50px) rotate(5deg);
        opacity: 0;
    }
}

.dym-office-container {
    display: block;
    position: fixed;
    bottom: 50px;
    right: 60px;
    cursor: pointer;
    z-index: 100;
}

#popup-dym:checked ~ .dym-office-container {
    display: none;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.close-button {
    position: absolute;
    right: 20px;
    top: 10px;
    cursor: pointer;
    align-self: flex-end;
    font-size: 16px;
    font-weight: 500;
    color: #202a5a;
}

.close-button:hover {
    font-weight: 800;
}

#popup-dym:checked ~ .dym-office {
    display: flex;
    animation: slide-skew 0.4s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

.dym-office {
    display: none;
    position: fixed;
    bottom: 50px;
    right: 60px;
    width: 150px;
    height: 260px;
    background-color: #ffffff;
    padding: 20px 35px;
    border-radius: 5px;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: flex-start;
    flex-wrap: wrap;
    color: #202a5a;
    font-size: 18px;
    font-weight: 500;
}

.dym-office > div {
    cursor: pointer;
}

.dym-office > div:hover {
    font-weight: 700;
    font-size: 20px;
}

@media (max-width: 650px) {
    #model {
        width: 240%;
        height: auto;
    }

    .header {
        padding: 20px;
    }

    .header-logo > img {
        width: 80px;
    }

    .header-logo > div {
        font-size: 12px;
        margin-top: 5px;
    }

    .btn-trigger {
        width: 25px;
        height: 18px;
        cursor: pointer;
    }

    .btn-trigger span:nth-of-type(2) {
        top: 7.5px;
    }

    #btn01.active span:nth-of-type(1) {
        -webkit-transform: translateY(7.5px) rotate(-45deg);
        transform: translateY(7.5px) rotate(-45deg);
    }

    #btn01.active span:nth-of-type(3) {
        -webkit-transform: translateY(-7.5px) rotate(45deg);
        transform: translateY(-7.5px) rotate(45deg);
    }

    .menu {
        top: 65px;
        right: 20px;
        width: 160px;
        height: 250px;
    }

    .menu > a {
        font-size: 16px;
    }

    .menu > a:hover {
        font-weight: 500;
        font-size: 18px;
    }
    

    .tooltip {
        top: 80px;
        padding: 10px 20px;
        font-size: 18px;
        font-weight: 600;
        text-align: center;
    }

    .tooltip::after {
        border-width: 20px 10px 0 10px;
    }

    .dym-office-container {
        bottom: 20px;
        right: 20px;
    }

    .dym-office {
        bottom: 20px;
        right: 20px;
        width: 100px;
        height: 160px;
        padding: 10px 20px;
        font-size: 14px;
    }

    .dym-office > div:hover {
        font-weight: 600;
        font-size: 15px;
    }
}