
.upper-main {
    height: 33%; 
    width: 100%; 
    background-color: #eee;
}

.type-dest {
    position: absolute; 
    top: 7.5px;
    left: 17.5px;
    font-size: 1.3rem;
    font-weight: 600;
}
.non-type {
    opacity: 0;
    width: 0 !important;
}

.type-outer, .dest {
    display: inline-block;
}

.type, .type-tmp {
    text-align: center;
    transform: translateY(-5%);
}
.type > span, .type-tmp > span {
    position: absolute;
    top: 0;
    left: 0;
    display: inline-block;
    height: 100%; width: 100%;
}

#type-en-tmp {
    width: fit-content;
}

.dest {
    transform: translateY(-5%);
    height: 30px;
}
.dest > span {
    position: absolute;
    top: 0;
    left: 0;
    display: inline-block;
    height: 100%; width: 100%;
}

.cars-number {
    position: absolute; 
    top: 10px; left: 592.5px;
    width: 35px; height: 35px;
    background-color: #fff;
    border-radius: 5px;
    text-align: center;
    line-height: 35px;
    font-size: 35px;
    font-weight: 400;
}
.cars-number-inner {
    display: inline-block;
    transform: translateY(-5%);
}

.cars-number-info {
    position: absolute;
    top: 45px;
    left: 592.5px;
    width: 35px;
    font-size: 12px;
    text-align: center;
}
.cars-number-info > span {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    display: inline-block;
}
#cars-number-info-en {
    transform: translate(-65px, -35px);
}

.next-str {
    font-size: 1.5rem;
    line-height: 1.5rem;
    font-weight: 600;
    width: 100px;
    text-align: center;
    position: absolute;
    top: 57px; left: 40px;
}
.next-str > span {
    position: absolute;
    top: 0;
    left: 0;
    display: inline-block;
    height: 100%; width: 100%;
}

.nextnumber-outer {
    font-size: 1.5rem;
    line-height: 1.5rem;
    position: absolute;
    top: 45px; left: 140px;
    height: 50px; width: 75px;
    text-align: center;
}

.nextnumber-inner {
    display: inline-block;
    position: relative;
}

.nextnumber-inner.subway {
    background-color: var(--subway-color);
    color: white;
    height: 1.8rem;
    width: 3.5rem;
    text-align: center;
    line-height: 1.8rem;
    font-weight: 500;
    margin: 10px;
}
.nextnumber-inner.hokushin {
    color: var(--subway-color);
    border: 2px solid var(--subway-color);
    height: 1.8rem;
    width: 3.5rem;
    text-align: center;
    line-height: 1.8rem;
    font-weight: 500;
    margin: 10px;
}
.nextnumber-inner.hk-kobe {
    color: var(--hk-kobe-color);
    border: 2px solid var(--hk-kobe-color);
    border-radius: 50px;
    box-sizing: border-box;
    height: 50px;
    width: 50px;
    font-weight: 600;
}
.nextnumber-inner.hk-takarazuka {
    color: var(--hk-takarazuka-color);
    border: 2px solid var(--hk-takarazuka-color);
    border-radius: 50px;
    box-sizing: border-box;
    height: 50px;
    width: 50px;
    font-weight: 600;
}
.nextnumber-inner.hk-kyoto {
    color: var(--hk-kyoto-color);
    border: 2px solid var(--hk-kyoto-color);
    border-radius: 50px;
    box-sizing: border-box;
    height: 50px;
    width: 50px;
    font-weight: 600;
}
.nextnumber-inner.nose {
    display: inline-block;
    background-color: var(--nose-color);
    border: 2px solid var(--nose-color);
    box-sizing: border-box;
    color: white;
    border-radius: 50px;
    height: 50px;
    width: 50px;
    font-weight: 600;
}
.stano-hk-hk {
    display: inline-block;
    position: absolute;
    font-size: 1rem;
    transform: scale(0.9);
    width: 46px;
    text-align: center;
    top: -2px;
    left: 0;
}
.stano-hk-no {
    display: inline-block;
    position: absolute;
    font-size: 1.4rem;
    width: 46px;
    text-align: center;
    top: 16px;
    left: 0;
}
.nextnumber-inner.sakaisuji {
    display: inline-block;
    background-color: var(--sakaisuji-color);
    color: white;
    height: 1.8rem;
    width: 3.5rem;
    text-align: center;
    line-height: 1.8rem;
    font-weight: 500;
    margin: 10px;
}
.nextnumber-inner.hanshin {
    color: var(--hanshin-color);
    border: 2px solid var(--hanshin-color);
    border-radius: 50px;
    box-sizing: border-box;
    height: 50px;
    width: 50px;
    font-weight: 600;
}
.nextnumber-inner.sanyo {
    display: inline-block;
    background-color: var(--sanyo-color);
    border: 2px solid var(--sanyo-color);
    box-sizing: border-box;
    color: white;
    border-radius: 50px;
    height: 50px;
    width: 50px;
    font-weight: 600;
}


.next-sta-name {
    font-size: 3.6rem;
    line-height: 3.6rem;
    font-weight: 600;
    width: 370px;
    height: 60px;
    text-align: center;
    perspective: 500px;
    position: absolute;
    top: 37.5px; left: 220px;
}
.next-sta-name > span {
    position: absolute;
    top: 0;
    left: 0;
    display: inline-block;
    height: 100%; width: 100%;
}
#next-sta-name-tmp {
    width: fit-content;
    white-space: nowrap;
}

.subname-outer {
    height: 20px;
    line-height: 17.5px;
    width: 100%;
    position: absolute;
    top: 98px;
    left: 0;
}

.subname-outer.subway { background-color: var(--subway-color); }
.subname-outer.hokushin { background-color: var(--hokushin-color); }
.subname-outer.hk-kobe { background-color: var(--hk-kobe-color); }
.subname-outer.hk-takarazuka { background-color: var(--hk-takarazuka-color); }
.subname-outer.hk-kyoto { background-color: var(--hk-kyoto-color); }
.subname-outer.nose { background-color: var(--nose-color); }
.subname-outer.sakaisuji { background-color: var(--sakaisuji-color); }

.subname-inner {
    margin-left: 125px;
    text-align: center;
    color: white;
    font-weight: 500;
    width: 500px;
    height: 100%;
}
.subname-inner > span {
    position: absolute;
    top: 0;
    left: 175px;
    display: inline-block;
    height: 100%; width: calc(100% - 175px);
}