/* 📄 保存先：style.css （完成版） */

/* --- Base & Variables --- */
:root {
    --primary-color: #0d6efd; 
    --secondary-color: #6c757d;
    --accent-color: #00bcd4;
    --dark-bg: #0a192f;
    --light-bg: #ffffff;
    --bg-soft: #f8f9fa;
    --text-dark: #212529;
    --text-light: #ccd6f6;
    --text-secondary: #495057;
    --heading-dark: #212529;
    --heading-light: #ffffff;
    --border-color: #dee2e6;
}

/* --- Global Styles --- */
body {
    margin: 0;
    font-family: 'Noto Sans JP', 'Inter', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.8;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 { font-weight: 700; color: var(--heading-dark); }
a { color: var(--primary-color); text-decoration: none; transition: all 0.3s ease; }
a:hover { color: #0a58ca; }
.container { max-width: 1140px; margin: 0 auto; padding: 0 20px; box-sizing: border-box; }
section { padding: 100px 0; }
.section-title { text-align: center; margin-bottom: 60px; }
.section-title h2 { font-size: 2.8rem; margin-bottom: 10px; }
.section-title p { font-size: 1.1rem; color: var(--text-secondary); max-width: 700px; margin: 0 auto; }
.cta-button { background-color: var(--primary-color); color: #fff; padding: 12px 28px; border-radius: 6px; font-weight: 500; display: inline-block; }
.cta-button:hover { background-color: #0a58ca; transform: translateY(-2px); }

/* --- Animation --- */
@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.fade-in { animation: fadeIn 1s ease-out forwards; animation-play-state: paused; } /* JSで制御するため初期は停止 */

/* --- Header --- */
.header { background: rgba(255, 255, 255, 0.95); padding: 15px 0; position: sticky; top: 0; width: 100%; z-index: 1000; backdrop-filter: blur(8px); border-bottom: 1px solid var(--border-color); }
.header .container { display: flex; justify-content: space-between; align-items: center; }
.header .logo { font-size: 1.6rem; font-weight: 700; color: var(--heading-dark); }
.header .nav-links a { margin: 0 20px; font-weight: 500; color: var(--text-dark); padding-bottom: 5px; border-bottom: 2px solid transparent; transition: all 0.3s ease; }
.header .nav-links a:hover { color: var(--primary-color); }
.header .nav-links a.active { color: var(--primary-color); font-weight: 700; border-bottom-color: var(--primary-color); }

/* --- Footer --- */
.footer { background-color: #212529; color: #f8f9fa; padding: 80px 0 40px; font-size: 0.95rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; }
.footer h4 { font-size: 1.2rem; margin-bottom: 20px; color: #fff; }
.footer-grid ul { list-style: none; padding: 0; }
.footer-grid ul li { margin-bottom: 12px; }
.footer-grid ul li a { color: #ced4da; }
.footer-grid ul li a:hover { color: #fff; }
.parent-company, .support-info { display: block; margin-top: 15px; font-size: 0.9rem; color: #adb5bd; }
.copyright { text-align: center; margin-top: 60px; padding-top: 30px; border-top: 1px solid #495057; color: #adb5bd; }

/* --- Page-Specific: index.php --- */
.hero { background-image: linear-gradient(rgba(10, 25, 47, 0.7), rgba(10, 25, 47, 0.7)), url('https://images.unsplash.com/photo-1542370285-b8eb8317691c?q=80&w=2070&auto=format&fit=crop'); background-size: cover; background-position: center; color: var(--heading-light); padding: 180px 0; text-align: center; }
.hero h1 { font-size: 4rem; margin-bottom: 20px; line-height: 1.2; color: var(--heading-light); }
.hero p { font-size: 1.25rem; max-width: 800px; margin: 0 auto 40px; color: var(--text-light); }

.service-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 30px; }
.service-card {
    display: flex; flex-direction: column; color: var(--heading-light); border-radius: 8px; text-align: center; position: relative; overflow: hidden;
    background-size: cover; background-position: center; transition: transform 0.4s ease, box-shadow 0.4s ease; min-height: 400px;
}
.service-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: linear-gradient(rgba(10, 25, 47, 0.4), rgba(10, 25, 47, 0.9)); z-index: 1; transition: background 0.4s ease; }
.service-card:hover { transform: translateY(-10px); box-shadow: 0 15px 40px rgba(0,0,0,0.2); }
.service-card:hover::before { background: linear-gradient(rgba(10, 25, 47, 0.2), rgba(10, 25, 47, 0.8)); }
.service-card .content {
    position: relative; z-index: 2; padding: 40px; display: flex; flex-direction: column; flex-grow: 1; justify-content: flex-end;
}
.service-card .icon { font-size: 3.5rem; color: var(--accent-color); margin-bottom: 20px; text-align: left; }
.service-card h3 { font-size: 1.8rem; text-align: left; margin: 0 0 10px; color: #fff; }
.service-card p { color: var(--text-light); text-align: left; margin: 0; }

.philosophy-section { background-color: var(--bg-light); }
.philosophy-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 40px; } /* 修正：text-alignを削除 */
.philosophy-item { text-align: center; } /* index.phpの理念用 */
.philosophy-item .icon { font-size: 3rem; color: var(--primary-color); margin-bottom: 15px; }
.philosophy-item h3 { font-size: 1.5rem; }

.tools-section { background-color: var(--dark-bg); }
.tools-section .section-title h2 { color: var(--heading-light); }
.tools-section .section-title p { color: var(--text-light); }
.form-container { background: #112240; padding: 40px; border-radius: 8px; box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1); max-width: 600px; margin: 0 auto; border: 1px solid #233554; }
.form-container h3 { color: var(--heading-light); }
.form-container input[type="url"] { width: 100%; padding: 15px; margin-bottom: 15px; border-radius: 6px; box-sizing: border-box; background-color: #0a192f; border: 1px solid #233554; color: var(--text-light); font-size: 1rem; }
.form-container button { width: 100%; padding: 15px; background: var(--accent-color); color: var(--heading-light); border: none; border-radius: 6px; font-weight: bold; font-size: 1rem; cursor: pointer; transition: 0.3s ease; }
.form-container button:hover { background: #0097a7; }
.message { margin-top: 20px; padding: 15px; border-radius: 6px; font-weight: 500; }
.message.success { background-color: #133b34; color: #64ffda; border: 1px solid #64ffda;}
.message.error { background-color: #3b1b23; color: #ff79c6; border: 1px solid #ff79c6;}

.about-content { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 60px; }
.about-content img { width: 100%; border-radius: 8px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); }


/* --- Page-Specific: about.php --- */
.page-hero { background-color: var(--bg-soft); padding: 80px 0; text-align: center; }
.page-hero h1 { font-size: 3rem; margin: 0; }
.philosophy-card { background: var(--bg-soft); padding: 40px; border-radius: 8px; text-align: center; }
.philosophy-card h3 { font-size: 1.5rem; color: var(--primary-color); }

.ceo-message { background-color: var(--bg-soft); }
.ceo-content { display: grid; grid-template-columns: 1fr 2fr; gap: 60px; align-items: center; }
.ceo-content img { width: 100%; border-radius: 8px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.ceo-content .quote { font-size: 1.8rem; font-weight: 700; line-height: 1.5; margin-bottom: 20px; }
.ceo-content .message { margin-top: 20px; font-size: 1.1rem; }
.ceo-content .name { font-size: 1.2rem; font-weight: 700; margin-top: 30px; }

.profile-table { width: 100%; border-collapse: collapse; }
.profile-table th, .profile-table td { padding: 20px; border-bottom: 1px solid var(--border-color); text-align: left; vertical-align: top;}
.profile-table th { width: 25%; font-weight: 700; background-color: var(--bg-soft); }

.history-section { background-color: var(--bg-soft); }
.timeline { border-left: 3px solid var(--primary-color); padding-left: 40px; position: relative; max-width: 800px; margin: 0 auto; }
.timeline-item { position: relative; margin-bottom: 40px; }
.timeline-item::before {
    content: ''; position: absolute; left: -49px; top: 5px;
    width: 15px; height: 15px; background: var(--primary-color); border-radius: 50%;
    border: 3px solid #fff;
}
.timeline-item:last-child { margin-bottom: 0; }
.timeline-item .year { font-size: 1.5rem; font-weight: 700; color: var(--primary-color); }
.timeline-item .event { font-size: 1.1rem; font-weight: 500; }

/* --- ハンバーガーメニュー --- */
.hamburger {
    display: none; background: none; border: none; font-size: 2.5rem;
    color: var(--heading-dark); cursor: pointer; z-index: 1001;
}

/* --- レスポンシブ対応 (992px以下のタブレットサイズ) --- */
@media (max-width: 992px) {
    .header .nav-links a { margin: 0 10px; }
    .about-content { grid-template-columns: 1fr; }
    .ceo-content { grid-template-columns: 1fr; text-align: center; }
    .ceo-content img { max-width: 250px; margin: 0 auto; }
}

/* --- レスポンシブ対応 (768px以下のモバイルサイズ) --- */
@media (max-width: 768px) {
    /* --- 基本スタイルの調整 --- */
    section { padding: 60px 0; }
    .section-title h2 { font-size: 2.2rem; }
    .hero h1 { font-size: 2.5rem; }
    .hero p { font-size: 1.1rem; }
    .page-hero h1 { font-size: 2rem; }

    /* --- ヘッダーのモバイル対応 --- */
    .header .cta-button { display: none; }
    .hamburger { display: block; }
    .header .nav-links {
        position: fixed; top: 0; right: -100%; width: 80%; height: 100vh;
        padding-top: 100px; background-color: var(--light-bg);
        box-shadow: -5px 0 15px rgba(0,0,0,0.1); display: flex;
        flex-direction: column; align-items: center; transition: right 0.4s ease-in-out;
    }
    .header .nav-links.active { right: 0; }
    .header .nav-links a { font-size: 1.5rem; margin: 20px 0; }
    body.no-scroll { overflow: hidden; }

    /* --- 各セクションのレイアウト調整 --- */
    .service-grid, .philosophy-grid, .footer-grid { grid-template-columns: 1fr; }
    .footer-grid { text-align: center; }
    .footer-grid div { margin-bottom: 30px; }
    .form-container { padding: 30px 20px; }
    .ceo-content .quote { font-size: 1.3rem; }

    /* --- テーブルのモバイル対応 --- */
    .profile-table, .profile-table th, .profile-table td { display: block; width: 100%; box-sizing: border-box; }
    .profile-table th { background-color: transparent; font-weight: 700; padding-bottom: 5px; border-bottom: none; }
    .profile-table td { padding-top: 0; border-bottom: 1px solid var(--border-color); margin-bottom: 20px; }
    .profile-table tr:last-child td { border-bottom: none; }
}