/* ============================================
   Base / Global
   ============================================ */
html {
    font-size: 20px;
    line-height: 1.5;
}
@media screen and (max-width: 1360px) {
    html {
        font-size: 17px;
    }
}
@media screen and (max-width: 890px) {
    html {
        font-size: 16px;
    }
}
@media screen and (max-width: 600px) {
    html {
        font-size: 14px;
    }
}

.p-br {
    display: none;
}

/* ============================================
   Components
   ============================================ */
hr.p-hr {
    max-width: 1280px;
    margin: 3em auto 0;
    border-top: 1px solid #000;
    opacity: 0.2;
}
@media screen and (max-width: 600px) {
    hr.p-hr {
        display: none;
    }
}

.link {
    /* ラッパー自体のスタイルが必要な場合はここに記述 */
}
.link a {
    padding-bottom: 1px;
    border-bottom: 2px solid #000;
    font-size: 1em;
    font-weight: 500;
    letter-spacing: 0.08em;
    opacity: 0.8;
}
.link a:hover {
    opacity: 1;
}
@media screen and (max-width: 890px) {
    .link {
        margin-bottom: 2rem;
    }
}

/* ============================================
   General Section Layout
   ============================================ */
/* 画像と動画の基本リセット */
#about-hero video,
#about-hero img,
.p-about-section video,
.p-about-section img {
    width: 100%;
}

.p-about-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    column-gap: 2rem;
    max-width: 1360px;
    margin-inline: auto;
    padding: 3rem 2rem 0;
}
@media screen and (max-width: 840px) {
    .p-about-section {
        display: block;
        margin-inline: auto;
        /* paddingは維持または上書き */
    }
}
@media screen and (max-width: 600px) {
    .p-about-section {
        padding: 5rem 1.5rem 0;
    }
}

/* テキストエリア */
.p-about-text {
    /* 必要に応じてスタイル追加 */
}
.p-about-text .p-about-text {
    padding-top: 0;
    text-align: left;
}
.p-about-text .title-en {
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    opacity: 0.5;
    line-height: 1.2;
}
.p-about-text .title-ja {
    margin-top: 1rem;
    font-size: 1.8rem;
    font-weight: 600;
    line-height: 1.2;
    word-break: keep-all;
    overflow-wrap: anywhere;
}
.p-about-text .text {
    margin-top: 1.8rem;
    font-size: 0.9rem;
    font-weight: 300;
    line-height: 1.75;
}
.p-about-text .text p {
    margin-top: 1em;
}
.p-about-text .text p.link {
    margin-top: 2.5rem;
}

@media screen and (max-width: 600px) {
    .p-about-text .text {
        margin-top: 2.2rem;
        font-size: 1.2rem;
		padding-bottom: 1rem;
	}
    .p-about-text .text p.link {
        margin-top: 1.5em;
        margin-bottom: 2em;
    }
}

/* メディアエリア（汎用） */
.p-about-media {
    /* 必要に応じてスタイル追加 */
}
@media screen and (max-width: 600px) {
    .p-about-media img,
    .p-about-media video {
        width: 100vw;
        /* 画面幅いっぱいに指定 */
        margin-left: calc(50% - 50vw);
        /* 親の中央(50%)から画面半分(50vw)を引いて左端に寄せる */
        margin-right: calc(50% - 50vw);
        max-width: 100vw;
        /* 安全策 */
    }
}

/* ============================================
   Specific Sections (IDs)
   ============================================ */

/* #dms */
#dms .p-about-media {
    max-width: 600px;
}
#dms .p-about-media video {
    aspect-ratio: 4 / 3;
    object-fit: cover;
}
@media screen and (max-width: 840px) {
    #dms .p-about-media {
        margin-top: 1.5rem;
        max-width: 100%;
    }
    #dms .p-about-media video {
        aspect-ratio: 1/1;
    }
}
@media screen and (max-width: 600px) {
    #dms .p-about-media video {
        
    }
}

/* #modules */
#modules {
    flex-direction: row-reverse;
}
#modules .p-about-text figure {
    max-width: 650px;
    margin-top: 1.2em;
}
#modules .p-about-media {
    width: 570px;
}
@media screen and (max-width: 840px) {
    #modules .p-about-text figure {
        max-width: 100%;
        margin-top: 1.5em;
    }
    #modules .p-about-media {
        width: 100%;
    }
    #modules .p-about-media video {
        aspect-ratio: 1/1;
        object-fit: cover;
    }
}
@media screen and (max-width: 600px) {
    #modules .p-about-text figure {
        width: 100vw;
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
        max-width: 100vw;
    }
}

/* #flexibility */
#flexibility {
    flex-direction: column;
    align-items: flex-start;
}
#flexibility .p-about-media {
    margin-top: 2em;
}
#flexibility .p-about-media img,
#flexibility .p-about-media video {
    aspect-ratio: 16/9;
    object-fit: cover;
}
@media screen and (max-width: 840px) {
    #flexibility .p-about-media {
        margin-top: 1.5em;
        max-width: 100%;
    }
    #flexibility .p-about-media video,
    #flexibility .p-about-media img {
        aspect-ratio: 1/1;
        object-fit: cover;
    }
}

/* #desk & #dashboard Shared */
#dashboard {
    flex-direction: row-reverse;
	margin-bottom: 5rem;
}
#desk .p-about-media,
#dashboard .p-about-media {
    width: 65%;
    max-width: 760px;
}
#desk .p-about-media img,
#dashboard .p-about-media img {
    aspect-ratio: 4/3;
    object-fit: cover;
}
@media screen and (max-width: 840px) {
    #desk .p-about-media,
    #dashboard .p-about-media {
        width: 100%;
        max-width: 840px;
    }
    #desk .p-about-media img,
    #dashboard .p-about-media img {
        aspect-ratio: 4/3;
        object-fit: cover;
    }
}
@media screen and (max-width: 600px) {
    #desk,
    #dashboard {
        margin: 1rem;
        display: flex;
        flex-direction: column-reverse;
        padding-right: 1px;
        padding-left: 1px;
        padding-top: 0;
        border-radius: 12px;
        overflow: hidden;
    }
    #desk {
        margin-top: 4rem;
		background-color: #757575;
    }
	#dashboard {
        margin-top: 4rem;
		background-color: #2b2b2b;
    }
    #desk .p-about-media img,
    #dashboard .p-about-media img {
        width: calc(100vw - 2rem); /* スペース修正済み */
        margin-right: -1px;
        margin-left: -1px;
    }
    #desk .p-about-text,
    #dashboard .p-about-text {
	padding: 2.5rem 2.5rem 0.5rem;
	color: #fff;
    }
    #desk .p-about-text .link a,
    #dashboard .p-about-text .link a {
        color: #fff;
        border-bottom-color: #fff;
        border-bottom-width: 1.5px;
    }
}

/* ============================================
   About Hero
   ============================================ */
#about-hero {
    position: relative;
    max-width: 1440px;
}
#about-hero figure img {
    aspect-ratio: 16/9;
    object-fit: cover;
}
#about-hero .p-about-text {
    position: absolute;
    bottom: 0;
    left: 0;
    margin: 2rem;
    padding: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(4px);
    color: #fff;
}
#about-hero .p-about-text .title-ja {
    margin-top: 0.4rem;
    font-size: 2.1rem;
}
#about-hero .p-about-text h2 i {
    font-size: 1.1em;
    font-style: normal;
    text-decoration: none;
    letter-spacing: 0.15em;
    margin-right: 0.1em;
}
#about-hero .p-about-text .text {
    margin-top: 1rem;
    font-size: 0.9rem;
    font-weight: 400;
    letter-spacing: 0.1em;
}

@media screen and (max-width: 600px) {
    #about-hero figure img {
        aspect-ratio: 1/1;
    }
    #about-hero .p-about-text {
        margin: 1rem;
        padding: 2rem 2rem 1.5rem;
    }
    #about-hero .p-about-text .title-ja {
        font-size: 2rem;
        margin-top: 0.5rem;
    }
    #about-hero .p-about-text .text {
        font-size: 1.1rem;
    }
}