/* 全体のスタイル */
:root {
    --primary-color: #e74c3c;
    --secondary-color: #f39c12;
    --text-color: #333;
    --background-color: #fff;
    --light-gray: #f5f5f5;
    --border-color: #ddd;
    --link-color: #e74c3c;
    --link-hover-color: #c0392b;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
}

a {
    color: var(--link-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--link-hover-color);
}

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

/* ヘッダー */
header {
    background-color: var(--background-color);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.site-title {
    font-size: 1.5rem;
    font-weight: bold;
}

.site-title a {
    color: var(--primary-color);
}

.main-nav ul {
    display: flex;
    list-style: none;
}

.main-nav li {
    margin-left: 20px;
}

.main-nav a {
    font-weight: 500;
}

/* フッター */
footer {
    background-color: var(--light-gray);
    padding: 30px 0;
    margin-top: 50px;
    border-top: 1px solid var(--border-color);
}

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

.footer-note {
    font-size: 0.8rem;
    color: #777;
    margin-top: 10px;
}

/* メインコンテンツ */
main {
    padding: 30px 0;
}

.page-header {
    text-align: center;
    margin-bottom: 30px;
}

.page-header h2 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.breadcrumb {
    margin: 10px 0 20px;
    font-size: 0.9rem;
    color: #777;
}

/* ヒーローセクション */
.hero-section {
    width: 100%;
    padding: 30px 20px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e7eb 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-section .hero-content {
    max-width: 800px;
    width: 100%;
    margin: 0 auto 40px;
    position: relative;
    z-index: 1;
}

.hero-content h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.hero-content p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 20px;
}

/* おすすめの著書セクション */
.featured-books {
    max-width: 900px;
    margin: 30px auto 0;
}

.featured-books h3 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.book-container {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.book-item {
    width: 300px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    background-color: white;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.book-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.hero-section .book-image {
    height: 180px;
    overflow: hidden;
    background-color: var(--light-gray);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
}

.hero-section .book-image img {
    max-width: 150px;
    max-height: 160px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.hero-section .book-info {
    padding: 15px;
    text-align: left;
}

.hero-section .book-info h4 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--text-color);
}

.hero-section .book-description {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 15px;
    line-height: 1.5;
}

.hero-section .book-link {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.hero-section .book-link:hover {
    background-color: var(--link-hover-color);
    color: white;
}

/* 新刊のお知らせセクション */
.featured-books {
    padding: 30px 0;
    background: linear-gradient(135deg, #fff8f0 0%, #ffefd5 100%);
    position: relative;
    overflow: hidden;
    margin: 30px auto;
    border-radius: 20px;
    width: 100%;
    max-width: 1000px;
}

.featured-books::before {
    content: '';
    position: absolute;
    top: -30%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255, 183, 107, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

.featured-books h3 {
    text-align: center;
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(45deg, #ff6b35, #f7931e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 25px;
    position: relative;
    z-index: 2;
}

.new-book-card {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.1);
    position: relative;
    z-index: 2;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.new-book-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 30px 80px rgba(0,0,0,0.15);
}

.new-badge {
    position: absolute;
    top: -15px;
    right: 30px;
    background: linear-gradient(45deg, #ff4757, #ff3742);
    color: white;
    padding: 10px 25px;
    border-radius: 50px;
    font-weight: bold;
    font-size: 0.9rem;
    box-shadow: 0 5px 15px rgba(255, 71, 87, 0.4);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.book-content {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 25px;
    align-items: start;
}

.book-image-section {
    text-align: center;
}

.book-image-section img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
}

.book-image-section img:hover {
    transform: scale(1.05);
}

.book-info h4 {
    font-size: 1.5rem;
    color: #333;
    margin-bottom: 15px;
    line-height: 1.3;
}

.amazon-exclusive {
    background: linear-gradient(135deg, #ff9500 0%, #ff7700 100%);
    color: white;
    padding: 10px 15px;
    border-radius: 10px;
    margin: 12px 0;
    text-align: center;
    font-weight: 600;
    font-size: 0.95rem;
}

.book-features {
    margin: 25px 0;
}

.feature-item {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #ff6b35;
}

.feature-icon {
    font-size: 1.5rem;
    margin-right: 12px;
}

.feature-text {
    font-size: 1rem;
    color: #555;
}

.price-info {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 8px;
    margin: 12px 0;
    text-align: center;
}

.price-main {
    font-size: 1.5rem;
    font-weight: bold;
    color: #ff6b35;
    margin-bottom: 5px;
}

.price-note {
    font-size: 0.9rem;
    color: #666;
}

.cta-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
}

.btn-book {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    text-align: center;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-amazon {
    background: linear-gradient(45deg, #ff9500, #ff7700);
    color: white;
    box-shadow: 0 5px 20px rgba(255, 149, 0, 0.4);
}

.btn-amazon:hover {
    background: linear-gradient(45deg, #e6850d, #e66b00);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 149, 0, 0.5);
    color: white;
    text-decoration: none;
}

.btn-rakuten {
    background: linear-gradient(45deg, #bf0000, #a00000);
    color: white;
    box-shadow: 0 5px 20px rgba(191, 0, 0, 0.4);
}

.btn-rakuten:hover {
    background: linear-gradient(45deg, #a60000, #8d0000);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(191, 0, 0, 0.5);
    color: white;
    text-decoration: none;
}

@media (max-width: 768px) {
    .featured-books {
        margin: 20px -10px;
        padding: 40px 20px;
    }
    
    .featured-books h3 {
        font-size: 2rem;
    }
    
    .new-book-card {
        padding: 30px 20px;
    }
    
    .book-content {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    
    .cta-buttons {
        flex-direction: column;
    }
}

.stats {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 30px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-number {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
}

.stat-label {
    font-size: 1rem;
    color: #666;
}

/* セクションスタイル */
.content-section {
    margin-bottom: 50px;
}

.section-title {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 20px;
    text-align: center;
}

/* レシピカード */
.recipe-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.recipe-card {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.recipe-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.recipe-image {
    height: 200px;
    overflow: hidden;
}

.recipe-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.recipe-card:hover .recipe-image img {
    transform: scale(1.05);
}

.recipe-content {
    padding: 15px;
}

.recipe-title {
    font-size: 1.2rem;
    margin-bottom: 10px;
    line-height: 1.4;
}

.recipe-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: #777;
    margin-bottom: 10px;
}

.recipe-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 15px;
}

.tag {
    display: inline-block;
    background-color: #f8e9e7;
    color: var(--primary-color);
    padding: 3px 8px;
    border-radius: 15px;
    font-size: 0.8rem;
    transition: background-color 0.3s ease;
}

.tag:hover {
    background-color: #f4d0ca;
}

.tag.active {
    background-color: var(--primary-color);
    color: white;
}

.recipe-link, .btn {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 8px 16px;
    border-radius: 4px;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.recipe-link:hover, .btn:hover {
    background-color: var(--link-hover-color);
    color: white;
}

/* タグクラウド */
.tag-cloud {
    text-align: center;
    margin: 20px 0;
    line-height: 2;
}

.view-more {
    text-align: center;
    margin-top: 20px;
}

/* タグ・カテゴリページ */
.tag-list, .category-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
    margin-bottom: 30px;
}

.tag-item, .category-item {
    background-color: var(--light-gray);
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.tag-item:hover, .category-item:hover {
    background-color: #f0f0f0;
}

.tag-link, .category-link {
    display: flex;
    justify-content: space-between;
    padding: 10px 15px;
    color: var(--text-color);
}

.tag-count, .category-count {
    color: #777;
    font-size: 0.9rem;
}

/* レシピリスト */
.recipe-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.recipe-item {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    padding: 15px;
}

.recipe-header {
    margin-bottom: 15px;
}

.recipe-body {
    display: flex;
    gap: 20px;
}

.recipe-body .recipe-image {
    width: 150px;
    height: 150px;
    flex-shrink: 0;
}

.recipe-body .recipe-content {
    flex-grow: 1;
    padding: 0;
}

.back-link {
    text-align: center;
    margin-top: 30px;
}

/* 検索ページ */
.search-container {
    max-width: 800px;
    margin: 0 auto 30px;
}

.search-form {
    display: flex;
    margin-bottom: 15px;
}

.search-form input {
    flex-grow: 1;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px 0 0 4px;
    font-size: 1rem;
}

.search-form button {
    border-radius: 0 4px 4px 0;
    border: none;
    cursor: pointer;
}

.search-options {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.search-stats {
    font-size: 0.9rem;
    color: #777;
    margin-bottom: 20px;
}

.search-empty {
    text-align: center;
    padding: 30px;
    color: #777;
}

/* 書籍ページ */
.book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.book-card {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.book-image {
    height: 200px;
    overflow: hidden;
    background-color: var(--light-gray);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
}

.book-image img {
    max-width: 200px;
    max-height: 200px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.book-info {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.book-title {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.book-meta {
    margin-bottom: 15px;
    font-size: 0.9rem;
}

.book-meta p {
    margin-bottom: 5px;
}

.book-action {
    margin-top: auto;
}

.no-image {
    height: 100%;
    background-color: var(--light-gray);
    display: flex;
    justify-content: center;
    align-items: center;
    color: #777;
}

/* アバウトページ */
.about-container {
    max-width: 800px;
    margin: 0 auto;
}

.about-section {
    margin-bottom: 30px;
}

.about-section h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.about-section p, .about-section ul {
    margin-bottom: 15px;
}

.about-section ul {
    margin-left: 20px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.stat-box {
    background-color: var(--light-gray);
    border-radius: 8px;
    padding: 15px;
    text-align: center;
}

.stat-box .stat-number {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.stat-box .stat-label {
    font-size: 0.9rem;
    color: #666;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .main-nav {
        margin-top: 10px;
        width: 100%;
    }
    
    .main-nav ul {
        flex-wrap: wrap;
    }
    
    .main-nav li {
        margin: 5px 10px 5px 0;
    }
    
    .recipe-body {
        flex-direction: column;
    }
    
    .recipe-body .recipe-image {
        width: 100%;
        height: 200px;
    }
    
    .stats {
        flex-wrap: wrap;
    }
    
    .recipe-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .recipe-grid {
        grid-template-columns: 1fr;
    }
}
