@charset "UTF-8";

:root {
    --color-pink: #F8C9BF;
    --color-light-green: #98DC94;
    --color-yellow: #DBDC94;
    --color-red: #F05B41;
}

html,
body {
    width: 100%;
    overflow-x: hidden;
    /* iOSでの横揺れ防止 */
    overscroll-behavior-x: none;
}

main {
    position: relative;
    width: 100%;
    height: 100svh;
}

.l-section {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 1;
}


.l-section:first-child {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.c-window {
    margin: 0 auto;
}

/* ==========================================================================
   bg
   ========================================================================== */

body::before {
    content: "";
    display: block;
    position: fixed;
    /* 画面に対して固定 */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-image: url('../../images/common/bg-grid.png');
    background-repeat: repeat;

    background-size: auto;
}

@keyframes noise-jump {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(30px, -10px);
    }
}

/* ==========================================================================
   Components / window
   ========================================================================== */
.c-window__header {
    position: absolute;
    font-size: var(--font-size-Text-S);
    top: 0;
    left: 0;
    width: 100%;
    height: 4em;
    border-radius: 16px 16px 0 0;
}

.c-window__header__red-dot {
    position: absolute;
    top: 1.6em;
    left: 2em;
    width: 1em;
    height: 1em;
    background-color: var(--color-red);
    border-radius: 50%;
}

.c-window__header__yellow-dot {
    position: absolute;
    top: 1.6em;
    left: 4.5em;
    width: 1em;
    height: 1em;
    background-color: var(--color-NUMATA-Orange);
    border-radius: 50%;
}

.c-window__header__green-dot {
    position: absolute;
    top: 1.6em;
    left: 7em;
    width: 1em;
    height: 1em;
    background-color: var(--color-NUMATA-Green);
    border-radius: 50%;
}

.c-window__header.u-blue {
    background-color: var(--color-NUMATA-LightBlue);
}

.c-window__header.u-green {
    background-color: var(--color-light-green);
}

.c-window__header.u-yellow {
    background-color: var(--color-yellow);
}

.c-window__header.u-pink {
    background-color: var(--color-pink);
}

.c-window.u-large {
    position: relative;
    width: 76%;
    border-radius: 16px;
    padding: 8em 6em 6em;
    background-color: var(--color-White);
    box-shadow: 4px 4px 10px 0 rgba(25, 36, 76, 0.20);
}

.c-window.u-medium {
    position: relative;
    width: 62%;
    border-radius: 16px;
    padding: 8em 6em 6em;
    background-color: var(--color-White);
    box-shadow: 4px 4px 10px 0 rgba(25, 36, 76, 0.20);
}

.c-window.u-regular {
    position: relative;
    width: 48%;
    border-radius: 16px;
    padding: 8em 6em 6em;
    background-color: var(--color-White);
    box-shadow: 4px 4px 10px 0 rgba(25, 36, 76, 0.20);

}

.c-window.u-small {
    position: relative;
    width: 34%;
    border-radius: 16px;
    padding: 6em 4em 1em;
    background-color: var(--color-White);
    box-shadow: 4px 4px 10px 0 rgba(25, 36, 76, 0.20);

}

@media screen and (max-width:1080px) {

    .c-window.u-large {
        width: 94%;
    }

    .c-window.u-medium {
        width: 83%;
    }

    .c-window.u-regular {
        width: 74%;
    }

    .c-window.u-small {
        width: 60%;
    }

}

@media screen and (max-width: 767px) {
    .c-window.u-large {
        padding: 5em 2em 4em;

    }

    .p-profile__inner {
        display: flex;
        gap: 5%;
    }

    .c-window.u-medium {
        padding: 3em 2em 2em;
    }

    .c-window.u-regular {
        width: 87%;
        padding: 3em 2em 2em;
        background-color: var(--color-White);
    }

    .c-window.u-small {
        width: 86%;
        padding: 3em 1em 1em;
    }

}

/* ==========================================================================
   Projects / section
   ========================================================================== */
.p-profile-wrapper {
    display: flex;
    gap: 4em;
    justify-content: space-between;
}

.p-profile-image {
    width: 40%;
    height: 40%;
    aspect-ratio: 1/1;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: auto 0
}

.p-profile-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.p-name-content {
    font-size: var(--font-size-Heading-R);
    margin-bottom: .5em;
}

.p-name-content__label {
    font-family: var(--En-font);
    font-size: var(--font-size-Text-L);
    font-weight: 900;
    letter-spacing: 0.15em;
    line-height: 1;
    color: var(--color-Primary);
    white-space: nowrap;
}

.p-name-content__name {
    position: relative;
    font-family: var(--Jp-font);
    font-size: var(--font-size-Heading-XL);
    font-weight: 900;
    letter-spacing: 0.15em;
    line-height: 1;
    color: var(--color-NUMATA-Green);
    width: 7em;
}

.p-name-content__name::before {
    content: "";
    display: inline-block;
    font-size: var(--font-size-Heading-R);
    margin-right: .25em;
    width: 1.2em;
    height: 1em;
    background-image: url(../../images/common/logo-symbol.svg);
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
}

.p-message-container {
    display: flex;
    flex-direction: row;
    gap: 4em;
}

.p-message-container__message {
    display: flex;
    justify-content: center;
    align-items: center;
}

.p-message-container__message p {
    font-family: var(--Jp-font);
    font-size: var(--font-size-Text-R);
    font-weight: 500;
    letter-spacing: 0.15em;
    line-height: 2;
    color: var(--color-Primary);
}

.p-profile .c-window {
    position: absolute;
    top: 10%;
    left: 3%;
    margin: 0;
}

.p-message .c-window {
    position: absolute;
    bottom: 15%;
    right: 8%;
    margin: 0;
}

.p-career__main-window {
    position: absolute;
    top: -20%;
    left: 0;
}

.p-career__sub-window.detail {
    position: absolute;
    bottom: 10%;
    left: 20%;
}

.p-career__sub-window.achievements {
    position: absolute;
    bottom: 10%;
    left: 57%;
}

.p-others .c-window {
    position: absolute;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(168px, 1fr));
    padding: 8em;
    gap: 4em 0;
}

.c-folder {
    display: block;
}

.c-folder__image {
    width: 10em;
    height: 10em;
    object-fit: contain;
    margin: 0 auto 0.5em;
    transition: all 0.3s ease;
}

.c-folder__tittle {
    display: block;
    font-family: var(--Jp-font);
    font-size: var(--font-size-Text-M);
    font-weight: 800;
    letter-spacing: 0.15em;
    line-height: 2;
    color: var(--color-Primary);
    text-align: center;
}

.c-folder-container:hover .c-folder__image {
    transform: scale(1.06);
}

.c-folder__link {
    display: inline-flex;
    /* 横並びにする */
    align-items: center;
    /* 垂直中央に揃える */
    text-decoration: none;
    color: inherit;
    width: 100%;
}

@media screen and (max-width:1080px) {
    .p-name-content__label {
        font-size: var(--font-size-Text-L);
    }

    .p-name-content__name::before {
        margin-right: .75em;
    }

    .p-name-content__name {
        font-size: var(--font-size-Heading-M);
    }

    .p-profile__sub-info {
        font-size: var(--font-size-Text-R);
    }

    .p-career__sub-window.detail {
        position: absolute;
        bottom: 26%;
        left: 4%;
    }

    .p-career__sub-window.achievements {
        position: absolute;
        bottom: 3%;
        left: 36%;
    }

}

@media screen and (max-width: 767px) {
    .p-profile-wrapper {
        display: flex;
        flex-flow: column;
    }

    .p-name-content__label {
        font-size: var(--font-size-Text-M);
    }

    .p-name-content__name::before {
        margin-right: .25em;
    }

    .p-name-content__name {
        font-size: var(--font-size-Heading-R);
    }

    .p-message-container {
        flex-direction: column;
        gap: 2em;
    }

    .p-message .c-window {
        bottom: 7%;
        left: 4%;
    }

    .p-career__main-window {
        top: -25%;
        left: 0;
    }

    .p-career__sub-window.detail {
        bottom: 30%;
        left: 2%;
    }

    .p-career__sub-window.achievements {
        bottom: 5%;
        left: 10%;
    }

    .p-others .c-window {
        padding: 4em 8px 2em;
    }

    .c-folder__image {
        width: 5em;
        height: 5em;
    }
}


/* ==========================================================================
   Modal Layout & Window Positioning
   ========================================================================== */

/* 1. モーダル背景 */
.p-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    /* モーダル本体(10000)より一つ下 */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(4px);
}

/* 2. モーダル本体コンテナ */
.p-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    /* GSAPの干渉を防ぎつつ中央固定 */
    transform: translate(-50%, -50%) scale(0.9);
    z-index: 10000;
    width: 90vw;
    height: 90vh;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
    /* absoluteな子要素をこの範囲内に収める */
}

/* 表示時の制御 */
.p-modal.is-show {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

.p-modal-overlay.is-show {
    opacity: 1;
    visibility: visible;
}

/* 3. モーダル内の各ウィンドウ共通設定（PC版） */
.p-modal .c-window {
    position: absolute;
    /* 自由に配置 */
    margin: 0;
    width: 45%;
    /* ウィンドウの基本サイズ（適宜調整してください） */
    max-width: 450px;
    box-shadow: 10px 20px 40px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s ease, z-index 0s;
}

.p-modal .c-window .c-text__description {
    word-break: normal;
}

/* --------------------------------------------------------------------------
   個別配置の割り当て (nth-child)
   ----------------------------------------------------------------------- */

/* 1番目のウィンドウ：左上 */
#modal-book-content .c-window:nth-child(1) {
    top: 30%;
    left: 35%;
    translate: -50% -50%;
    z-index: 10;
}

/* 2番目のウィンドウ：中央右寄り */
#modal-book-content .c-window:nth-child(2) {
    top: 50%;
    left: 75%;
    translate: -50% -50%;
    z-index: 20;
}

/* 3番目のウィンドウ：左下 */
#modal-book-content .c-window:nth-child(3) {
    top: 73%;
    left: 45%;
    translate: -50% -50%;
    z-index: 30;
}

/* 1番目のウィンドウ：左上 */
#modal-recomend-content .c-window:nth-child(1) {
    top: 26%;
    left: 30%;
    translate: -50% -50%;
    z-index: 10;
}

/* 2番目のウィンドウ：中央右寄り */
#modal-recomend-content .c-window:nth-child(2) {
    top: 53%;
    left: 50%;
    translate: -50% -50%;
    z-index: 20;
}

/* 3番目のウィンドウ：左下 */
#modal-recomend-content .c-window:nth-child(3) {
    top: 80%;
    left: 70%;
    translate: -50% -50%;
    z-index: 30;
}

/* --------------------------------------------------------------------------
   レスポンシブ対応（スマホ版はスクロール可能な縦並びへ）
   ----------------------------------------------------------------------- */
@media screen and (max-width: 767px) {
    .p-modal {
        overflow-y: auto;
        display: block;
        padding: 60px 20px;
    }

    .p-modal .c-window {
        width: 68%;
    }

    #modal-book-content .c-window:nth-child(1) {
        top: 16%;
        left: 35%;
    }

    #modal-book-content .c-window:nth-child(2) {
        top: 48%;
        left: 65%;
    }

    #modal-book-content .c-window:nth-child(3) {
        top: 78%;
        left: 35%;
    }

    #modal-recomend-content .c-window:nth-child(1) {
        top: 20%;
        left: 35%;
    }

    #modal-recomend-content .c-window:nth-child(2) {
        top: 50%;
        left: 50%;
    }

    #modal-recomend-content .c-window:nth-child(3) {
        top: 80%;
        left: 65%;
    }
}

/* 閉じるボタン等 */
.js-close-modal {
    cursor: pointer;
}

.js-close-modal:hover {
    opacity: 0.7;
}