/**
 * add custom author page Plugin - Stylesheet
 * 著者ボックスのスタイル
 */

/* 著者ボックス全体のコンテナ */
.acap-author-box {
    display: grid;
    grid-template-columns: 100px 1fr;
    grid-template-rows: auto auto;
    grid-template-areas:
        "title title"
        "img profile"
        "subtitle subtitle"
        "article article";
    gap: 0 30px;
    font-size: 14px;
    padding: 25px;
    border: 0.5px solid rgba(11, 2, 118, 0.2);
    background-color: rgba(11, 2, 118, 0.05);
    margin: 2em 0;
    border-radius: 8px;
}

.acap-author-box__title {
    grid-area: title;
    font-size: 1.8rem;
    border-bottom: 0.5px solid rgba(11, 2, 118, 0.2);
    padding-bottom: 4px;
    margin-top: 0;
    margin-bottom: 20px;
}

.acap-author-box__img {
    grid-area: img;
    height: auto;
    margin-bottom: 15px;
}

.acap-author-box__img img {
    border-radius: 50%;
    vertical-align: bottom;
}

.acap-author-box__profile {
    grid-area: profile;
    margin-top: 0;
}

.acap-author-box__profile .acap-author-box__profile__title {
    font-size: 1.8rem;
    margin-top: 0 !important;
}

.acap-author-box__profile .acap-author-box__profile__text {
    margin: 16px 0 0;
}

.acap-author-box__profile .acap-author-box__profile__text p {
    margin: 0;
}

.acap-author-box__profile .acap-author-box__profile__text p+p {
    margin-top: 1em;
}

.acap-author-box__profile .acap-author-box__profile__link {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.acap-author-box__profile .acap-author-box__profile__link a {
    width: 32px;
    height: 32px;
    display: inline-block;
    transition: all 0.3s;
}

.acap-author-box__profile .acap-author-box__profile__link a:hover {
    opacity: 0.7;
}

.acap-author-box__subtitle {
    grid-area: subtitle;
    font-size: 1.6rem;
    color: #333;
    border-bottom: 0.5px solid rgba(11, 2, 118, 0.2);
    margin-top: 0;
    margin-bottom: 10px;
    padding-bottom: 5px;
}

.acap-author-box__article {
    grid-area: article;
    display: flex;
    flex-wrap: wrap;
    gap: 16px 2%;
}
.acap-author-box__article .newlab-article__item {
    width: 23.5%;
}

@media screen and (max-width: 768px) {
    .acap-author-box {
        grid-template-columns: 60px 1fr;
        gap: 0 16px;
    }    
    .acap-author-box__article .newlab-article__item {
        width: 49%;
    }
}

/* アバター部分 */
.acap-author__avatar {
    flex-shrink: 0;
    /* アバターが縮まないようにする */
}

.acap-author__avatar img {
    border-radius: 50%;
    /* アバター画像を円形にする */
    max-width: 100px;
    /* PCでの最大幅 */
    height: auto;
    display: block;
}

/* 著者情報（テキスト）部分 */
.acap-author__info {
    flex: 1;
    /* 残りのスペースをすべて使用 */
}

/* 著者名 */
.acap-author__name {
    margin: 0 0 8px 0;
    font-size: 1.3em;
    font-weight: bold;
}

.acap-author__name a {
    text-decoration: none;
    color: #222;
}

.acap-author__name a:hover {
    text-decoration: underline;
}

/* 自己紹介文 */
.acap-author__description {
    margin: 0 0 16px 0;
    font-size: 0.95em;
    color: #555;
}

/* SNSリンクのコンテナ */
.acap-author-sns {
    display: flex;
    flex-wrap: wrap;
    /* 画面が狭い場合に折り返す */
    gap: 16px;
    /* リンク間のスペース */
}

/* 個別のSNSリンク */
.acap-author-sns a {
    text-decoration: none;
    font-weight: 500;
    color: #1a73e8;
    /* リンクの色 */
}

.acap-author-sns a:hover {
    text-decoration: underline;
}

/* スマートフォン向けのレスポンシブ対応 */
@media (max-width: 600px) {
    .acap-author-box {
        flex-direction: column;
        /* 縦並びに変更 */
        align-items: center;
        /* 中央揃えにする */
        text-align: center;
        /* テキストも中央揃え */
    }

    .acap-author-avatar img {
        max-width: 80px;
        /* スマホでは少し小さく */
    }

    .acap-author-sns {
        justify-content: center;
        /* SNSリンクを中央に配置 */
    }
}