/* Kodama Publishing - Common Styles */

/* リセットと基本スタイル */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #4A90E2;
    --primary-hover: #357ABD;
    --secondary-color: #2c3e50;
    --text-color: #333;
    --text-light: #666;
    --text-lighter: #777;
    --text-muted: #999;
    --background-color: #f8f7f4;
    --white: #fff;
    --border-color: #ddd;
    --border-light: #eee;
    --shadow: rgba(0,0,0,0.1);
    --shadow-hover: rgba(0,0,0,0.15);
}

/* 言語固有のフォント設定 */
body.en {
    font-family: 'Georgia', 'Times New Roman', serif;
}

body.ja {
    font-family: 'Hiragino Kaku Gothic ProN', 'ヒラギノ角ゴ ProN', 'メイリオ', Meiryo, sans-serif;
}

body {
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ヘッダースタイル */
header {
    background: var(--white);
    box-shadow: 0 2px 5px var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-top {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-light);
}

.header-top .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 28px;
    font-weight: bold;
    color: var(--secondary-color);
    text-decoration: none;
}

.header-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

.search-bar {
    display: flex;
    border: 1px solid var(--border-color);
    border-radius: 25px;
    overflow: hidden;
}

.search-bar input {
    border: none;
    padding: 8px 15px;
    width: 250px;
    outline: none;
    font-family: inherit;
}

.search-bar button {
    background: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 8px 20px;
    cursor: pointer;
    font-family: inherit;
}

.search-bar button:hover {
    background: var(--primary-hover);
}

.language-switch {
    color: var(--text-light);
    text-decoration: none;
    padding: 5px 10px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
}

.language-switch:hover {
    background: #f0f0f0;
}

/* ナビゲーション */
nav {
    padding: 15px 0;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
}

nav a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s;
}

nav a:hover {
    color: var(--primary-color);
}

/* ヒーローセクション */
.hero {
    background: linear-gradient(rgba(102, 126, 234, 0.6), rgba(118, 75, 162, 0.6)), url('/img/hero.jpg');
    background-size: cover;
    background-position: center;
    color: var(--white);
    padding: 80px 0;
    text-align: center;
    position: relative;
}

/* 言語固有のヒーローサイズ */
.en .hero h1 {
    font-size: 48px;
    margin-bottom: 20px;
    font-weight: normal;
}

.ja .hero h1 {
    font-size: 42px;
    margin-bottom: 20px;
    font-weight: bold;
}

.hero p {
    font-size: 20px;
    margin-bottom: 30px;
}

.cta-button {
    display: inline-block;
    background: var(--white);
    color: #667eea;
    padding: 15px 40px;
    border-radius: 30px;
    text-decoration: none;
    font-size: 18px;
    transition: transform 0.3s;
    font-weight: bold;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* セクション共通スタイル */
section {
    padding: 60px 0;
}

/* 言語固有のセクションタイトル */
.en .section-title {
    font-size: 36px;
    text-align: center;
    margin-bottom: 40px;
    color: var(--secondary-color);
}

.ja .section-title {
    font-size: 32px;
    text-align: center;
    margin-bottom: 40px;
    color: var(--secondary-color);
    font-weight: bold;
}

/* 注目書籍グリッド */
.books-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.book-card {
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px var(--shadow);
    transition: transform 0.3s;
}

.book-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px var(--shadow-hover);
}

.book-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.book-link .book-card {
    cursor: pointer;
}

.book-link:hover .book-card {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px var(--shadow-hover);
}

.book-cover {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
}

.book-info {
    padding: 20px;
}

/* 言語固有の書籍タイトル */
.en .book-title {
    font-size: 20px;
    margin-bottom: 5px;
    color: var(--secondary-color);
}

.ja .book-title {
    font-size: 18px;
    margin-bottom: 5px;
    color: var(--secondary-color);
    font-weight: bold;
}

.book-author {
    color: var(--text-light);
    margin-bottom: 10px;
}

.ja .book-author {
    font-size: 14px;
}

.book-description {
    font-size: 14px;
    color: var(--text-lighter);
    margin-bottom: 15px;
    line-height: 1.5;
}

.ja .book-description {
    line-height: 1.6;
}

.book-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.book-price {
    font-size: 20px;
    color: var(--primary-color);
    font-weight: bold;
}

.book-category {
    background: #f0f0f0;
    padding: 5px 15px;
    border-radius: 15px;
    font-size: 12px;
    color: var(--text-light);
}

/* カテゴリーグリッド */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.category-card {
    background: var(--white);
    padding: 30px;
    text-align: center;
    border-radius: 10px;
    box-shadow: 0 2px 5px var(--shadow);
    transition: all 0.3s;
    cursor: pointer;
}

.category-card:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px var(--shadow-hover);
}

.category-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.category-name {
    font-size: 18px;
    margin-bottom: 5px;
    color: var(--secondary-color);
}

.ja .category-name {
    font-weight: bold;
}

.category-count {
    color: var(--text-muted);
    font-size: 14px;
}

/* 著者スポットライト */
.author-spotlight {
    background: var(--white);
    border-radius: 10px;
    padding: 40px;
    display: flex;
    gap: 40px;
    align-items: center;
    box-shadow: 0 3px 10px var(--shadow);
}

.author-image {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
}

/* 言語固有の著者情報 */
.en .author-info h3 {
    font-size: 28px;
    margin-bottom: 10px;
    color: var(--secondary-color);
}

.ja .author-info h3 {
    font-size: 26px;
    margin-bottom: 10px;
    color: var(--secondary-color);
    font-weight: bold;
}

.author-bio {
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 20px;
}

.author-books {
    color: var(--primary-color);
    text-decoration: none;
}

.ja .author-books {
    font-weight: bold;
}

/* ニュース・イベント */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.news-item {
    background: var(--white);
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 5px var(--shadow);
}

.news-date {
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 10px;
}

/* 言語固有のニュースタイトル */
.en .news-title {
    font-size: 20px;
    margin-bottom: 10px;
    color: var(--secondary-color);
}

.ja .news-title {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--secondary-color);
    font-weight: bold;
}

.news-excerpt {
    color: var(--text-light);
    line-height: 1.6;
}

/* ニュースレター */
.newsletter {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
    color: var(--white);
    padding: 60px 0;
    text-align: center;
}

/* 言語固有のニュースレタータイトル */
.en .newsletter h2 {
    font-size: 36px;
    margin-bottom: 20px;
}

.ja .newsletter h2 {
    font-size: 32px;
    margin-bottom: 20px;
    font-weight: bold;
}

.newsletter p {
    font-size: 18px;
    margin-bottom: 30px;
}

.newsletter-form {
    display: flex;
    justify-content: center;
    gap: 10px;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 15px;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-family: inherit;
}

.newsletter-form button {
    background: var(--secondary-color);
    color: var(--white);
    border: none;
    padding: 15px 30px;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    font-family: inherit;
}

.ja .newsletter-form button {
    font-weight: bold;
}

.newsletter-form button:hover {
    background: #1a252f;
}

/* フッター */
footer {
    background: var(--secondary-color);
    color: var(--white);
    padding: 40px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 30px;
}

.footer-section h3 {
    margin-bottom: 15px;
}

.ja .footer-section h3 {
    font-weight: bold;
}

.footer-section ul {
    list-style: none;
}

.footer-section a {
    color: #ccc;
    text-decoration: none;
    line-height: 2;
}

.footer-section a:hover {
    color: var(--white);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #444;
    color: var(--text-muted);
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    background: #444;
    border-radius: 50%;
    text-align: center;
    line-height: 40px;
    color: var(--white);
    text-decoration: none;
}

.social-links a:hover {
    background: var(--primary-color);
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .header-top .container {
        flex-direction: column;
        gap: 15px;
    }

    .search-bar input {
        width: 150px;
    }

    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }

    .en .hero h1 {
        font-size: 32px;
    }

    .ja .hero h1 {
        font-size: 28px;
    }

    .hero p {
        font-size: 16px;
    }

    .author-spotlight {
        flex-direction: column;
        text-align: center;
    }

    .newsletter-form {
        flex-direction: column;
    }
}