body{
     font-family: "M PLUS U", sans-serif;
}
header{
    background-color: #f3f9f9;
}
header .wrapper {
    display: flex;
    margin: 0 auto;
    align-items: center;
    justify-content: space-between;
    font-weight: 500;
}
.header-logo {
    margin-left: 20px;
}
.header-list ul{
    display: flex;
    align-items: center;
    margin-right: 20px;
}

.header-list li{
    list-style: none;
    margin-left: 20px;
}
.header-list ul li a{
    text-decoration: none;
    color: #333333;
}
.header-list ul li a:hover{
    color: #666666;             /* 少しグレーっぽくする */
    border-bottom: 2px solid #333333; /* 下線を追加する */
    padding-bottom: 4px;        /* 下線と文字の間に少し隙間を作る */
    transition: 0.3s;           /* パッと変わるのではなく、ふわっと色を変える */
}
.container{
    max-width: 900px;
    width: 90%;
    margin: 0 auto;
    justify-content: space-between;
}
.content-wrapper{
    display: flex;
    gap: 40px;
}
main h1{
    text-align: center;
    margin-top: 80px;
}
main h2{
    text-align: center;
}
.about p{
    max-width: 100%;
    line-height: 1.8;
}
.skills ul li{
    list-style: none;
    margin-bottom: 8px;
}
.about, .skills {
  flex: 1;          /* 均等に幅を分ける */
}
.skills ul{
    margin: 0;
    padding-bottom: 20px;
    padding-left: 0;

}
.skills h3{
    margin-bottom: 10px;
}
.floating-btn{
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    text-decoration: none;
    color: inherit;
    display: inline-block;
    color: white;
    background-color: darkslategray;
    padding: 10px 20px;
    border-radius: 40px;
}
section h2 {
  text-align: left;
  margin-top: 40px; /* 必要であれば余白も調整 */
}
.portfolio-contents{
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
}
.portfolio-item{
    width: calc(25% - 15px);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    height: 300px;
}
.portfolio-item img{
    width: 100%;
    height: 200px;
    display: block;
    object-fit: cover;
    border-radius: 8px;
}
.service-contents{
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
}
.service-item{
    width: calc(33.33% - 15px);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    height: 200px;
    gap: 15px;
    align-items: flex-start;
}
.service-icon{
    width: 50px;
    flex-shrink: 0;
}
.icon-wrapper{
    width: 50px;
    flex-shrink: 0;
}
.icon-wrapper img{
    width: 100%;
    height: auto;
}
.text-wrapper h3{
    margin-top: 0px;
    margin-bottom: 10px;
}
.about-container{
    display: flex;
    align-items: flex-start;
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
}
.about-image{
    width: 300px;
    flex-shrink: 0;
}
.about-image img{
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}
.about-content{
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}
.about-content dl{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.about-content dt{
    grid-column: span 2;
    font-weight: bold;
}
/* お問い合わせセクション全体 */
.contact {
    padding: 60px 20px;
    max-width: 800px;
    margin: 0 auto;
}

/* セクションタイトル */
.section-title {
    text-align: center;
    margin-bottom: 40px;
    font-size: 2rem;
}

/* フォーム本体 */
.contact-form {
    background-color: #f9f9f9;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* 入力グループの余白 */
.form-group {
    margin-bottom: 20px;
}

/* 横並び設定（PC用） */
.form-row {
    display: flex;
    gap: 20px;
}

/* ラベルのスタイル */
label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

/* 入力欄・セレクトボックス・テキストエリアの共通スタイル */
input, select, textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 16px; /* スマホでタップした時にズームしないサイズ */
    box-sizing: border-box; /* パディングを含めて幅を計算させる */
}

/* 送信ボタン */
.submit-btn {
    width: 100%;
    padding: 15px;
    background-color: #001a33;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 18px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.submit-btn:hover {
    background-color: #003366;
}



/* --- スマホ用 --- */
@media (max-width: 768px) {
    header .header-list ul {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    padding: 0;         /* リストの初期余白を消す */
    list-style: none;  /* 黒点を消す */
    }
    
    .service-item {
    width: 100%;       /* 幅を広げて縦並びに合わせる */
    height: auto;      /* 高さを固定せず中身に合わせる */
    padding: 15px;     /* 余白を確保して文字の窮屈さを解消 */
    }
    .service-item p, 
    .service-item h3 {
    word-break: keep-all; 
    }
    .about-content dl {
    grid-template-columns: 1fr; /* スマホでは1列にする */
    }
}