/* ==========================================
   1. デザイン変数 & 全体設定
   ========================================== */
:root {
    --main-blue: #260edd;
    --accent-blue: #4419ff;
    --recruit-bg: rgba(38, 14, 221, 0.05);
    --text-dark: #333;
    --bg-light: #f9f9f9;
}

body { 
    font-family: "Helvetica Neue", Arial, "Hiragino Sans", "Meiryo", sans-serif; 
    line-height: 1.8; 
    color: var(--text-dark); 
    margin: 0; 
    background: #fff;
    scroll-behavior: smooth;
}

.container { 
    max-width: 1100px; 
    margin: 0 auto; 
    padding: 0 20px; 
}

/* ==========================================
   2. タイポグラフィ（見出し・文字）
   ========================================== */
/* 見出しの色を本文色に統一（!importantでHTML内のインライン指定を強制上書き） */
h1, h2, h3 { color: var(--text-dark) !important; }

/* ページタイトルボックス（alliance / partner 用） */
.page-title-box { 
    text-align: center; 
    border: 1px solid var(--main-blue); 
    padding: 30px; 
    border-radius: 8px; 
    margin: 40px 0; 
}
.page-title-box h1 { margin: 0; font-size: 2.2rem; font-weight: bold; }

/* セクションリード文（index / products用） */
.section-lead {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 50px;
    font-size: 0.95rem;
    color: #666;
    line-height: 1.8;
}

/* ==========================================
   3. 共通コンポーネント（ボタン・ナビ・カード）
   ========================================== */
/* ヘッダー・ロゴ */
header { border-bottom: 1px solid #eee; background: #fff; position: sticky; top: 0; z-index: 100; }
.header-flex { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; padding: 10px 0; }

.logo-link { 
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 2.0rem; 
    font-weight: bold; 
    color: #13076e; /* ロゴに寄せた深い青 */
    text-decoration: none; 
    transition: 0.3s; 
}
.header-logo { height: 1.2em; width: auto; display: block; }

/* ボタン・共通形状設定 */
.btn-top, .btn-recruit, .btn-submit, nav a, .header-banner { 
    border-radius: 6px; 
    text-decoration: none; 
    font-weight: bold; 
    display: inline-block; 
    transition: 0.3s; 
    text-align: center;
}

.btn-top { border: 1px solid var(--main-blue); color: var(--main-blue); padding: 5px 18px; font-size: 0.75rem; }
.btn-top:hover { background: var(--main-blue); color: #fff; }

.btn-recruit, .btn-submit { background: var(--main-blue); color: #fff; padding: 15px 30px; border: none; cursor: pointer; }
.btn-recruit:hover, .btn-submit:hover { background: var(--accent-blue); }

nav a { border: 1px solid var(--main-blue); padding: 5px 12px; font-size: 0.85rem; color: var(--text-dark); }
nav a:hover { background: var(--accent-blue); border-color: var(--accent-blue); color: #fff; }

.header-banner { background: var(--main-blue); color: #fff; font-size: 0.75rem; padding: 6px 15px; border-radius: 20px; }

/* 各種カードの共通設定（枠線・角丸） */
.card, .recruit-card, .alliance-card, .course-card, .feature-item { 
    border-radius: 8px; 
    border: 1px solid #eee; 
    padding: 25px; 
    background: #fff; 
    transition: 0.3s; 
}

/* フォーム要素 */
input, textarea, select { border-radius: 4px; border: 1px solid #ccc; padding: 12px; width: 100%; box-sizing: border-box; }

/* ==========================================
   4. セクション固有設定
   ========================================== */
/* ヒーローエリア (index.html) */
#hero-section { 
    position: relative; height: 550px; overflow: hidden; background-color: #000; 
    display: flex; align-items: center; justify-content: center; text-align: center; 
    background-size: cover; background-position: center; transition: background-image 1.5s ease-in-out; 
}
#hero-section h2, #hero-section p { color: #fff !important; }
.hero-text { max-width: 850px; padding: 20px; opacity: 0; transition: opacity 1s; text-shadow: 2px 2px 4px rgba(0,0,0,0.8); }
.hero-text.visible { opacity: 1; }

/* ボックス内タイトルの下線を全ページで統一 */
.card h4, .recruit-card h4, .alliance-card h3, .course-card h3 {
    color: var(--text-dark);
    margin-top: 0;
    margin-bottom: 15px;
    padding-bottom: 10px;
    font-weight: bold;
    border-bottom: 1px solid var(--accent-blue);
}

/* 取扱商材 (Products) */
.product-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 25px; }
#products .card h4 i { color: var(--accent-blue); margin-right: 10px; }
.etc-card { background: #fff !important; border-style: dashed !important; }

/* 事業概要 (Company) */
#company h3 {
    text-align: left !important; border-left: 6px solid var(--accent-blue);
    padding: 2px 0 2px 15px !important; margin-bottom: 25px;
}
.company-list { background: var(--bg-light); padding: 40px; border-radius: 8px; }
dl { display: grid; grid-template-columns: 200px 1fr; border-top: 1px solid #ddd; margin: 0; }
dt { font-weight: bold; padding: 20px 0; color: var(--text-dark); border-bottom: 1px solid #ddd; }
dd { margin: 0; padding: 20px 0; border-bottom: 1px solid #ddd; }

/* ==========================================
   5. その他（レスポンシブ・フッター・開発用）
   ========================================== */
footer { background: #fff; text-align: center; padding: 50px 0; font-size: 0.8rem; color: #999; border-top: 1px solid #eee; margin-top: 50px; }

/* モバイル調整（768px以下で発動） */
@media (max-width: 768px) {
    /* インデックス用(.header-flex)と下層ページ用(.header-top)の両方を縦並びに強制 */
    .header-flex, .header-top {
        display: flex !important;
        flex-direction: column !important; 
        align-items: center !important; 
        gap: 20px !important; 
        padding: 20px 0 !important; 
    }
    
    /* スマホでは文字が溢れないよう、ロゴのフォントサイズを微調整 */
    .logo-link { 
        justify-content: center; 
        font-size: 1.6rem; /* 2.0rem から少し縮小して一行に収める */
    }
    
    /* 募集バナーをスマホ向けに調整 */
    .header-banner { width: auto; max-width: 90%; margin: 0 auto; }
    
    /* メニューリンクの中央寄せと余白リセット */
    nav { 
        display: flex; 
        flex-wrap: wrap; 
        justify-content: center; 
        gap: 10px; 
    }
    nav a { 
        margin: 0 !important; 
        font-size: 0.85rem;
        padding: 6px 12px;
    }

    /* 各種コンテンツの1カラム化 */
    .product-grid { grid-template-columns: 1fr; }
    .section-lead { text-align: left; padding: 0 10px; margin-bottom: 30px; }
    
    /* 事業概要のテーブル状レイアウトを解除 */
    dl { grid-template-columns: 1fr; }
    dt { padding: 15px 0 5px; border-bottom: none; }
    dd { padding: 0 0 15px; border-bottom: 1px solid #ddd; }
}


/* ヘッダーの最上部に細い帯を追加 */
.top-utility-bar {
    background-color: #f8f9fa; /* 薄いグレーでメインエリアと分離 */
    border-bottom: 1px solid #eee;
    padding: 5px 0;
    font-size: 0.75rem; /* 少し小さめに */
}

.top-utility-flex {
    display: flex;
    justify-content: flex-end; /* 右寄せ */
    align-items: center;
}

/* プルダウンの見た目をシンプルに */
.lang-dropdown {
    position: relative;
    display: inline-block;
}

.lang-current {
    cursor: pointer;
    color: #666;
    font-weight: 500;
    padding: 2px 8px;
    display: flex;
    align-items: center;
    transition: color 0.2s;
}

.lang-current:hover {
    color: var(--main-blue); /* ホバー時にテーマカラーへ */
}

.lang-current i {
    margin-right: 5px; /* 地球儀アイコン用 */
}

.lang-current::after {
    /* \f107 の前にバックスラッシュがあることを確認してください */
    content: "\f107" !important;
    
    /* ソースコード通りの名前に修正 */
    font-family: "Font Awesome 7 Free" !important;
    font-weight: 900 !important;
    
    /* アイコンとして認識させるための必須セット */
    display: inline-block !important;
    font-style: normal !important;
    font-variant: normal !important;
    text-rendering: auto !important;
    -webkit-font-smoothing: antialiased !important;
    
    /* サイズと位置の調整 */
    margin-left: 5px;
    font-size: 0.7rem;
    line-height: 1;
}
/* メニューのデザインもフラットに */
.lang-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    min-width: 130px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    z-index: 1000;
    border-radius: 4px;
    overflow: hidden;
}

.lang-menu a {
    color: #333;
    padding: 8px 15px;
    text-decoration: none;
    display: block;
}

.lang-menu a:hover {
    background-color: #f0f4f8;
    color: var(--main-blue);
}

.lang-dropdown:hover .lang-menu {
    display: block;
}
/* 開発用パネル */
#dev-panel { 
    display: none; position: fixed; bottom: 20px; right: 20px; z-index: 9999; 
    background: #fff; padding: 20px; border-radius: 12px; box-shadow: 0 10px 40px rgba(0,0,0,0.3); 
    border: 1px solid #ddd; width: 230px; 
}
.code-box { margin-top: 15px; font-family: monospace; font-size: 11px; background:#f4f4f4; padding:10px; border-radius:4px; line-height:1.5; }