body {
    font-family: Arial, sans-serif;
    color: #333;
    margin: 0;
    padding: 0;
}

.hero {
    position: relative;
    height: 70vh;
    background: none;
    background-size: cover;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 0 40px;
    overflow: hidden;
}

.hero-text {
    max-width: 60%;
    text-align: left;
    z-index: 3;
    font-size: 2em;
    line-height: 1.2;
    font-weight: bold;
    margin: 0;
    font-family: 'serif', 'Times New Roman', 'ヒラギノ明朝 ProN W3', 'Hiragino Mincho ProN', 'MS 明朝', 'MS Mincho';
    color: white;
}

.hero h1 {
    margin: 0;
    font-size: 1.8em;
    line-height: 1.2;
}

.hero p {
    margin-top: 10px;
    font-size: 1em;
    line-height: 1.2;
    color: white;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../img/introduction-back.jpg') no-repeat center center;
    background-size: cover;
    opacity: 0.5;
    z-index: 1;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.3);
    z-index: 2;
}

.company-name {
    font-size: 1.5em;
    font-weight: normal;
    margin-top: 10px;
    color: white;
    font-family: 'serif', 'Times New Roman', 'ヒラギノ明朝 ProN W3', 'Hiragino Mincho ProN', 'MS 明朝', 'MS Mincho';
}

nav {
    background-color: rgb(72, 146, 100);
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background-color: rgb(72, 146, 100);
    height: 80px;
}

.logo {
    max-height: 100%;
    display: flex;
    align-items: center;
}

.nav-links {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

.nav-links li {
    margin-left: 20px;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-size: 1em;
    display: inline-block;
    line-height: 80px;
}

.nav-links a :hover {
    opacity: 0.7;
}

.hamburger {
    display: none; /* 確実に表示されるように設定 */
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 40px; /* 幅を設定 */
    height: 30px; /* 高さを設定 */
    z-index: 1000; /* 他の要素の上に表示 */
    background-color: transparent; /* 背景色を透明に設定 */
    border: none; /* ボーダーを削除 */
    cursor: pointer; /* カーソルをポインタに設定 */
}

.hamburger-line {
    width: 100%;
    height: 5px; /* 線の高さを設定 */
    background-color: white; /* 線の色を白に設定 */
    margin: 4px 0; /* 線同士の間隔を調整 */
}

/* タブレットおよびスマホ表示時の設定 */
@media (max-width: 1024px) {
    .nav-container {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 20px;
        background-color: rgb(72,146,100);
    }

    .logo-container{
        flex-grow: 1;
    }

    .hamburger-container {
        display: flex;
        justify-content: flex-end;
        align-items: center;
    }

    .hamburger {
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .hamburger-line {
        width: 100%;
        height: 3px;
        background-color: white;
        margin: 4px 0;
    }

    .nav-links {
        display: none; /* デフォルトは非表示 */
        flex-direction: column;
        align-items: center;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(65, 171, 108, 0.8);
        transform: translateY(-100%);
        transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
        opacity: 0;
        z-index: 1000;
    }

    .nav-links.show {
        display: flex;
        transform: translateY(0);
        opacity: 1;
    }

    .nav-links li {
        margin: 20px 0;
    }

    .nav-links a{
        font-size: 2em;
        font-weight: bold;
        color: white;
        text-decoration: none;
        text-align: center;
    }
    
    .nav-links a:hover{
        color: #fff;
    }


}

/* モバイルビューのロゴとハンバーガーメニューの中央揃え (480px以下) */
@media (max-width: 480px) {
    .nav-container {
        height: 60px;
        justify-content: space-between;
        align-items: center;
    }

    .logo {
        max-height: 50px;
    }

    .hamburger {
        display: flex;
        margin-left: 10px;
        justify-content: center;
        align-items: center;
    }
}

.container {
    width: 80%;
    margin: 0 auto;
    padding: 20px 0;
}

h2 {
    font-size: 2em;
    margin-bottom: 20px;
    color: rgb(72, 146, 100);
}

h3 {
    font-size: 1.5em;
    margin-bottom: 15px;
    color: #333;
}

p {
    color: #666;
    line-height: 1.8;
}

.services-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
    margin: 0 auto;
    max-width: 1200px;
    align-items: stretch;
}

.service-item {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    flex: 1 1 calc(33.333% - 20px);
    box-sizing: border-box;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.service-item img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    margin-top: 15px;
    opacity: 0.85;
    transition: opacity 0.3s ease;
    flex-shrink: 0;
}

.service-item img:hover {
    opacity: 1;
}

.voice-grid {
    display: flex;
    gap: 20px;
    margin-top: 20px;
    justify-content: space-between;
}

.voice-item {
    display: flex;
    align-items: flex-start;
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    flex: 1;
    margin-bottom: 20px;
}

.voice-img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin-right: 20px;
    object-fit: cover;
}

.voice-content {
    max-width: 70%;
}

.voice-content h3 {
    font-size: 1.2em;
    margin-bottom: 5px;
    color: rgb(72, 146, 100);
}

.voice-content h3 .voice-bold {
    font-size: 2em;
    color: #8B0000;
}

.voice-content h4 {
    font-size: 1em;
    margin-bottom: 10px;
    color: #333;
}

.voice-content p {
    color: #666;
    line-height: 1.8;
}

footer {
    background-color: #333;
    color: white;
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
}

footer p {
    margin: 5px 0;
}

/* メディアクエリの設定（レスポンシブデザイン対応） */
@media (max-width: 1024px) {
    .services-grid {
        flex-direction: column;
    }
    .service-item {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .service-item {
        width: 100%;
        margin-bottom: 15px;
    }

    .services-grid {
        flex-direction: column;
        gap: 15px;
    }

    .hero {
        height: 50vh;
        padding: 0 20px;
        justify-content: flex-start;
        text-align: left;
    }

    .hero-text {
        font-size: 1.5em;
        max-width: 100%;
    }

    .hero h1 {
        font-size: 1.2em;
    }

    .hero p {
        font-size: 0.8em;
    }

    .nav-container {
        flex-direction: column;
        align-items: flex-start;
    }

    .nav-links {
        flex-direction: column;
        align-items: flex-start;
    }

    .nav-links li {
        margin: 10px 0;
    }
}

@media (max-width: 480px) {
    .service-item {
        width: 100%;
        margin-bottom: 10px;
    }

    .service-item h3 {
        text-align: center;
        font-size: 0.9em;
    }


    .services-grid {
        flex-direction: column;
        gap: 10px;
    }
}

@media (max-width: 768px) {
    .voice-grid {
        flex-direction: column;
        gap: 15px;
    }

    .voice-item {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .voice-img {
        margin: 0 0 15px 0;
    }

    .voice-content {
        max-width: 100%;
    }

    .voice-content h3 {
        font-size: 1.2em;
    }

    .voice-content h4 {
        font-size: 1em;
    }

    .voice-content p {
        font-size: 0.9em;
    }
}

@media (max-width: 480px) {
    .hero {
        height: 40vh;
    }

    .hero-text {
        font-size: 1em;
    }

    .hero h1 {
        font-size: 1.4em !important;
        white-space: nowrap;
    }

    .hero p {
        font-size: 0.8em !important;
    }

    .nav-container {
        align-items: center;
    }

    .nav-links {
        align-items: center;
    }

    .nav-links li {
        margin: 5px 0;
    }
}

@media (max-width: 480px) {
    .voice-grid {
        flex-direction: column;
        gap: 10px;
    }

    .voice-item {
        padding: 15px;
        text-align: center;
    }

    .voice-img {
        width: 60px;
        height: 60px;
        margin: 0 0 10px 0;
    }

    .voice-content h3 {
        font-size: 1.1em;
    }

    .voice-content h4 {
        font-size: 0.9em;
    }

    .voice-content p {
        font-size: 0.8em;
    }
}
