@font-face {
    font-family: 'Raleway';
    src: url('../fonts/Raleway-Italic-VariableFont_wght.ttf') format('truetype');
    font-weight: bold;
}

html {
    font-family: "Raleway", sans-serif;
    margin:0 auto;
    max-width: 1200px;
}

section {
    margin: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
}

.section_menu {
    text-align: center;
    line-height: 230px;
    height: 230px;
    overflow: hidden;
    display: block; 
    text-decoration: none;
    color: inherit;
    transition: opacity 0.5s ease;
}


.section_menu:nth-child(1) { background-color: #217a00; }
.section_menu:nth-child(2) { background-color: #48922d; }
.section_menu:nth-child(3) { background-color: #62ad47; }
.section_menu:nth-child(4) { background-color: #aaea93; }
.section_menu:nth-child(5) { background-color: #dadada; }
.section_menu:nth-child(6) { background-color: #7a7a7a; }
.section_menu:nth-child(7) { background-color: #494949; }
.section_menu:nth-child(8) { background-color: #000000; }


.viewchara {
    color: #fff;
    position: relative;
    background-color: black;
    overflow: hidden;
}

.viewchara::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url(../img/icon.png); 
    background-size: 200px 200px;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0;
    transition: opacity 0.5s ease;
    z-index: 1;
}

.viewchara:hover::before {
    opacity: 1;
}

main {
    text-align: center;
}

.mouson:hover {
    opacity: 0.5;
    transform: translateY(-10px); /* 要素を上に移動 */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

@keyframes loop_animation {
    0% {
        transform: translateY(-100%);
    }
    100% {
        transform: translateY(100vh);
    }
}

.animation_loop1 {
    animation: loop_animation 5s linear infinite;
    white-space: nowrap;
}

.animation_loop2 {
    animation: loop_animation 5s linear infinite;
    white-space: nowrap;
}

.animation_loop1 img, .animation_loop2 img {
    width: 20%;
}

h1 {
    font-size: 15px;
}
h2 {
    font-size: 50px;
    position: relative;
    display: inline-block;
    margin-bottom: 1em;
    padding: 2px;
}

h2:before {
content: '';
position: absolute;
bottom: -15px;
display: inline-block;
width: 60px;
height: 5px;
left: 50%;
-webkit-transform: translateX(-50%);
transform: translateX(-50%);
background-color: black;
border-radius: 2px;
}

h3 {
    font-size: 30px;
    text-decoration: underline;
    text-decoration-color: #181616cf; /* 下線の色 */
    text-decoration-thickness: 2px; /* 下線の太さ */
}
h4 {
    font-size: 20px;
    max-width: 60%;
    margin: 0 auto;
    text-align: left;
    padding-top:10px;
}

p {
    max-width: 600px;
    text-align: left;
    margin: 5px auto;
}

.description {
    font-size: 15px;
}

.Qualifications {
    max-width: 400px;
    margin: 0 auto;
}

#profile {max-width: 400px;}

ul {
    list-style-type: none; /* 中点を削除 */
}

li {
    padding: 5px;
    text-align: left;
}

/* 進捗バーの外枠 */
.progress-bar {
    width: 60%;
    background-color: #e0e0e0; /* 背景色 */
    border-radius: 5px; /* 角を丸くする */
    height: 30px; /* 高さを設定 */
    position: relative; /* 内部の要素の位置を相対的にする */
    margin: 10px auto; /* 上下に余白を追加 */
}

/* 進捗の部分 */
.progress-bar-fill {
    height: 100%; /* 高さを進捗バーに合わせる */
    background-color: #034213; /* 進捗の色 */
    text-align: center; /* テキストを中央揃えにする */
    line-height: 30px; /* テキストの縦位置を中央にする */
    position: relative; /* テキストラベルの位置を相対的にする */
    color: #fff; /* テキストの色 */
    font-weight: bold; /* テキストを太字にする */
}

.progress-bar-fill2 {
    height: 100%; /* 高さを進捗バーに合わせる */
    background-color: #4fc500; /* 進捗の色 */
    text-align: center; /* テキストを中央揃えにする */
    line-height: 30px; /* テキストの縦位置を中央にする */
    position: relative; /* テキストラベルの位置を相対的にする */
    color: #fff; /* テキストの色 */
    font-weight: bold; /* テキストを太字にする */
}

/* 進捗ラベルのスタイル */
.progress-bar-label1 {
    position: absolute;
    width: 100%;
    left: 0;
    top: 50%;
    transform: translateY(-50%); /* テキストを中央に垂直配置 */
}

.progress-bar-label2 {
    position: absolute;
    width: 100%;
    left: 0;
    top: 50%;
    transform: translateY(-50%); /* テキストを中央に垂直配置 */
}

footer {
    background-color: #034213;
    margin:10px auto;
    max-width: 1200px;
    text-align: center;
    color: #fff;
    height: 50px;
    line-height: 50px;
}

.coll_img p {
    display: flex;
    flex-direction: column;
    align-items: center; /* 横方向の中央揃え */
    justify-content: center; /* 縦方向の中央揃え */
    text-align: center; /* テキストを中央揃え */
}

.coll_img img {
    width: 200px;
    display: block;
    margin: 0 auto;
}

.coll_img a {
    display: inline-block; /* リンクをインラインブロックにして、リンク範囲を画像のサイズに合わせる */
    margin: 0 auto;
}

.jirei {
    display: -webkit-box;
    -webkit-line-clamp: 3; /* 表示する行数 */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    max-height: 4.5em; /* 行数 × 行の高さ */
    line-height: 1.5em; /* 行の高さ */
}

.jirei.expanded {
    -webkit-line-clamp: unset; /* 行制限を解除 */
    max-height: none; /* 高さ制限を解除 */
}

.toggle-btn {
    display: block;
    margin-top: 10px;
    cursor: pointer;
}

/* ボタンの基本スタイル */
button {
    margin: 0 auto;
    background-color: #02380d; /* ボタンの背景色 */
    color: white; /* ボタンの文字色 */
    border: none; /* ボタンの枠線を消す */
    padding: 10px 20px; /* ボタンの内側の余白 */
    font-size: 12px; /* ボタンの文字サイズ */
    border-radius: 5px; /* ボタンの角を丸くする */
    cursor: pointer; /* ホバー時にポインタに変わる */
    transition: background-color 0.3s, transform 0.2s; /* ホバー時のトランジション */
}

/* ホバー時のスタイル */
button:hover {
    background-color: #006531; /* ホバー時の背景色 */
    transform: scale(1.05); /* ホバー時に少し拡大する */
}

/* フォーカス時のスタイル */
button:focus {
    outline: none; /* フォーカス時のアウトラインを消す */
    box-shadow: 0 0 0 3px rgba(109, 228, 103, 0.464); /* フォーカス時のシャドウ */
}


@media screen and (max-width: 600px) {
    section {
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* 横に2等分 */
    }
}