/* 基本スタイル */
body {
    margin: 0;
    font-family: "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
    line-height: 1.6;
    color: #333;
}

/* ヘッダー */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: url('catalog.jpg') center/cover no-repeat;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    text-align: center;
    color: #fff;
    overflow: hidden;
    z-index: 1;
}

header h1 {
    font-size: 3rem;
    opacity: 0;
    animation: fadeIn 1s forwards 0.5s;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

header p {
    font-size: 1.5rem;
    opacity: 0;
    animation: fadeIn 1s forwards 1s;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 本文コンテンツ */
.main-content {
    position: relative;
    z-index: 10;
    margin-top: 100vh;
    background-color: #fff;
}

.logo {
    display: block;
    margin: 0 auto;
    padding: 60px 0 40px 0;
    max-width: 500px;
    width: 90%;
}

/* 応募ボタン（追従） - 修正 */
.apply-fixed {
    position: fixed;
    top: -100px; /* 初期状態では画面外へ */
    left: 50%;
    transform: translateX(-50%);
    transition: top 0.4s ease;
    z-index: 999;
    background: none;
    padding: 0;
}

.apply-fixed.show {
    top: 20px; /* 表示時の位置 */
}

.apply-fixed img {
    border: none;
    vertical-align: middle; /* 画像の下にできる余白を削除 */
}

.apply-fixed .banner-sp {
    display: none; /* デフォルト(PC)ではスマホ用を非表示 */
}


/* 各セクション共通 */
section {
    padding: 10px 20px 40px 20px;
    max-width: 1000px;
    margin: 0 auto;
}

section h2 {
    font-size: 2rem;
    margin-bottom: 10px;
    text-align: center;
}

section h3 {
    font-size: 1.2rem;
    margin-bottom: 30px;
    color: #888;
    text-align: center;
}

/* 会社情報・採用情報のテーブル */
#company table, #careers table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 40px;
}
#company th, #company td, #careers th, #careers td {
    border: 1px solid #ccc;
    padding: 15px;
    vertical-align: top;
    text-align: left;
}
#company th, #careers th {
    background-color: #f9f9f9;
    width: 25%;
}
#careers td ul {
    margin: 0;
    padding-left: 20px;
}

/* 社長メッセージ */
#top-message {
    padding: 40px 20px;
    background-color: #fafafa;
}

.message-sticky-container {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.message-content {
    display: flex;
    align-items: center;
    gap: 20px;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.message-content.active {
    opacity: 1;
    transform: translateY(0);
}

.message-content img {
    width: 300px;
    height: auto;
    border-radius: 8px;
    flex-shrink: 0;
}

.message-content .text {
    flex: 1;
}

.message-content .text h4 {
    font-size: 1.5rem;
    margin-top: 0;
}

/* 社員紹介（MEMBER'S DAY） */
.member-header {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.member-titles {
    text-align: center;
    margin: 0 20px;
}

/* セクション内の見出しの上下余白をリセット */
#member-day h2,
#member-day h3 {
    margin-top: 0;
    margin-bottom: 0;
}

.member-arrow {
    /* 円の形とサイズ */
    width: 40px;
    height: 40px;
    border-radius: 50%; /* この指定で正円になります */

    /* 見た目 */
    background-color: #fff;
    border: 1px solid #ccc;
    color: #333;
    font-size: 1.5rem; /* 円に合わせたフォントサイズに調整 */
    
    /* 矢印を円の真ん中に配置 */
    display: flex;
    justify-content: center;
    align-items: center;
    
    /* 基本設定 */
    cursor: pointer;
    flex-shrink: 0;
    transition: background-color 0.2s; /* ホバー時のアニメーション */
}

.member-arrow:hover {
    background-color: #f0f0f0; /* マウスを乗せると背景色が変わる */
}

.member-slider-container {
    /* 位置指定と内側余白をリセット */
    position: static;
    padding: 0;
}

.member-slide {
    display: none;
    gap: 40px;
    align-items: flex-start;
    min-height: 500px;
}

.member-slide.active {
    display: flex;
}

.member-profile {
    flex-basis: 35%;
    text-align: center;
}

.member-profile img {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 20px;
    border: 3px solid #f0f0f0;
}

.member-profile h4 {
    font-size: 1.2rem;
    margin: 0 0 10px 0;
}

.member-profile p {
    font-size: 0.9rem;
    text-align: left;
    color: #555;
}

.member-schedule {
    flex-basis: 65%;
}

.member-schedule table {
    width: 100%;
    border-collapse: collapse;
}

.member-schedule th, .member-schedule td {
    border: 1px solid #e0e0e0;
    padding: 10px;
    text-align: left;
    font-size: 0.9rem;
}

.member-schedule th {
    background-color: #f9f9f9;
}

.member-schedule td:first-child {
    width: 80px;
    text-align: center;
    color: #777;
}

/* フッター */
footer {
    background: #f4f4f4;
    padding: 40px 20px;
    text-align: center;
}

.apply-bottom {
    display: inline-block;
    background: #e74c3c;
    color: #fff;
    padding: 15px 30px;
    border-radius: 5px;
    font-size: 1.2rem;
    text-decoration: none;
    transition: background-color 0.3s;
}

.apply-bottom:hover {
    background-color: #c0392b;
}

/* レスポンシブ対応 - 修正 */
@media (max-width: 768px) {
    header h1 { font-size: 2rem; }
    header p { font-size: 1.2rem; }

    section { padding: 20px 20px; }
    
    /* ① テーブルの表示崩れを修正 */
    /* display: block; を指定していた部分を削除し、PCと同じテーブル表示を維持 */
    #company th, #careers th {
        width: 30%; /* スマホでは見出し列の幅を少し広げる */
    }

    /* ③ 追従バナーのスマホ/PC切り替え */
    .apply-fixed .banner-pc {
        display: none; /* スマホではPC用を非表示 */
    }
    .apply-fixed .banner-sp {
        display: inline; /* スマホ用を表示 */
    }

    #top-message {
        background-image: url('img/catalog_down.jpg');
        background-size: cover;
        background-position: center;
    }

    .message-content, .member-slide.active {
        flex-direction: column;
        text-align: center;
    }
    .message-content img {
        width: 100%;
        max-width: 100%;
        margin-bottom: 20px;
    }

    /* ② スライダーの矢印を左右中央に配置するためpaddingを調整 */
    .member-slider-container {
        padding: 0 45px;
    }
    .member-profile {
        width: 100%;
    }
    .member-schedule {
        width: 100%;
    }
}