/* =================================================
   全体の基本設定
   ================================================= */
body {
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
}

/* =================================================
   ヘッダー基本設定
   ================================================= */
header {
    background-color: #ffffff;
    border-bottom: 1px solid #eee;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-logo {
    height: 40px;
    width: auto;
    display: block;
}

.menu-icon {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 6px;
    z-index: 1001;
}

.menu-icon span {
    width: 30px;
    height: 3px;
    background-color: #333;
}

.nav-area ul {
    display: flex;
    gap: 30px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-area a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-area a:hover {
    color: #004a99;
}

/* =================================================
   メインコンテンツ以降の通常スタイル（PC向け基準）
   ================================================= */
.main-visual {
    background-image: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)), url('images/hero.jpg');
    background-size: cover;
    background-position: center;
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #fff;
    text-align: center;
}

.main-visual-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    font-family: "Times New Roman", "Yu Mincho", "MS Mincho", serif;
    font-style: italic;
    letter-spacing: 0.1em;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.6);
}

.section-container {
    padding: 80px 5%;
    text-align: center;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
}

.bg-light {
    background-color: #f9f9f9;
}

h2 {
    border-left: 5px solid #004a99;
    padding-left: 15px;
    margin-bottom: 20px;
    text-align: left;
}

.news-section {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px 0;
    text-align: left;
}

.news-list {
    list-style: none;
    padding: 0;
    text-align: left;
    max-width: 100%;
    margin: 0 auto;
}

.news-list li {
    border-bottom: 1px solid #ddd;
    padding: 20px 10px;
    display: flex;
    align-items: baseline;
    gap: 30px;
}

.news-list span {
    color: #333; 
    font-weight: 600;
    font-size: 1rem;
    min-width: 110px;
    margin-right: 0;
    flex-shrink: 0;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background-color: #004a99;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    margin-top: 20px;
}

/* =================================================
   事業内容セクション (Services)
   ================================================= */
#services {
    position: relative;
    background-image: 
    linear-gradient(rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.85)), 
    url('images/service-hero.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    padding: 100px 5%;
    overflow: hidden;
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.service-card {
    background: rgba(255, 255, 255, 0.95);
    padding: 40px 30px;
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.service-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    background: #fff;
}

.service-icon {
    font-size: 1.2rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #004a99;
    margin-bottom: 10px;
    display: block;
}

.service-card h3 {
    font-size: 1.25rem;
    line-height: 1.4;
    margin-bottom: 20px;
    color: #1a1a1a;
    font-weight: 700;
}

.service-card p {
    font-size: 0.95rem;
    line-height: 1.8;
    color: #555;
    text-align: justify;
}

/* =================================================
   会社概要セクション (About)
   ================================================= */
#about {
    position: relative;
    background-image: 
    linear-gradient(rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.85)), 
    url('images/company.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    padding: 100px 5%;
    overflow: hidden;
}

#about .container > table,
#about .ceo-message {
    background: rgba(255, 255, 255, 0.95);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

/* =================================================
   お問い合わせフォーム
   ================================================= */
.contact-form {
    max-width: 600px;
    margin: 40px auto 0;
    text-align: left;
    background: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: bold;
    margin-bottom: 8px;
    color: #333;
}

.form-group input, 
.form-group select, 
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    font-family: inherit;
}

.form-group input:focus, 
.form-group textarea:focus {
    border-color: #0056b3;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0,86,179,0.1);
}

.contact-form .btn {
    width: 100%;
    border: none;
    cursor: pointer;
}

/* =================================================
   フッター
   ================================================= */
footer {
    background-color: #1a1a1a;
    color: #fff;
    padding: 60px 0 20px;
    text-align: center;
}

.footer-logo {
    width: 280px;
    height: auto;
    object-fit: contain;
    display: block;
    margin-bottom: 15px;
    opacity: 0.9;
    transition: opacity 0.3s;
}

.footer-logo:hover {
    opacity: 1;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    max-width: 1100px;
    margin: 0 auto 40px;
    padding: 0 20px;
    text-align: left;
}

.footer-info {
    text-align: left;
    margin-bottom: 20px;
}

.footer-right-block {
    text-align: right;
}

.footer-info h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.footer-info p {
    font-size: 0.9rem;
    color: #bbb;
}

.footer-links {
    list-style: none;
    display: flex;
    gap: 25px;
    margin-bottom: 15px;
    padding: 0;
    justify-content: flex-end;
}

.footer-links.policy-links {
    margin-bottom: 20px;
}

.footer-links a {
    color: #fff;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: #007bff;
}

.copyright {
    font-size: 0.8rem;
    color: #888;
    margin-top: 20px;
}


/* =================================================
   ★【重要】スマホ・タブレット表示（画面幅1000px以下）
   ※必ずCSSの一番最後に置くことで、スマホ時に確実に優先されます
   ================================================= */
@media (max-width: 1000px) {
    /* 1. 全体の横スクロール・はみ出しを強制カット */
    html, body {
        overflow-x: hidden;
        width: 100%;
    }

    .container, .news-section {
        width: 100% !important;
        max-width: 100% !important;
        padding-left: 15px !important;
        padding-right: 15px !important;
        box-sizing: border-box !important;
    }

    .section-container {
        padding: 50px 15px !important;
    }

    /* 2. メインビジュアルの見出しサイズをスマホ用に自動縮小 */
    .main-visual-content h1 {
        font-size: 1.8rem !important;
        letter-spacing: 0.05em !important;
        padding: 0 10px;
    }

   /* 3. お知らせ（ニュース）リストを縦並びに切り替え */
    .news-list li {
        display: flex !important;
        flex-direction: column !important; /* スマホでは上下に縦並び */
        align-items: flex-start !important;
        gap: 5px !important;
        padding: 15px 0 !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .news-list .news-date {
        font-size: 0.9rem !important;
        color: #004a99 !important;
        font-weight: 600;
        width: 100% !important;
    }

    .news-list .news-text {
        width: 100% !important;
        display: block !important;
        word-break: break-all !important; /* スマホの画面端で確実に折り返す */
        overflow-wrap: break-word !important;
        line-height: 1.6;
        font-size: 0.95rem !important;
    }
    /* 4. フッターのスマホ崩れ防止（縦並び・中央揃え） */
    .footer-content {
        flex-direction: column !important;
        text-align: center !important;
        align-items: center !important;
        gap: 30px !important;
    }

    .footer-info {
        text-align: center !important;
    }

    .footer-right-block {
        text-align: center !important;
        width: 100% !important;
    }

    .footer-logo {
        width: 100% !important;
        max-width: 200px !important;
        height: auto !important;
        margin: 0 auto 15px !important;
    }

    .footer-links {
        justify-content: center !important;
        flex-wrap: wrap !important;
        padding: 0 !important;
        gap: 15px !important;
    }
}