/* Hero Section */
.hero {
    position: relative;
    padding: 5rem 0 2rem;
    overflow: hidden;
}

@media (min-width: 768px) {
    .hero {
        padding: 6rem 0 3rem;
    }
}

.japanese-pattern {
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23c4b5a4' fill-opacity='0.15'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.hero-container {
    position: relative;
}

.hero-content {
    max-width: 48rem;
    margin: 0 auto;
    text-align: center;
}

.hero-title-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    animation: fade-in 0.5s ease-out both;
}

.hero-image {
    flex-shrink: 0;
}

.hero-image img {
    width: 5rem;
    height: 5rem;
    border-radius: 1rem;
    object-fit: cover;
}

@media (min-width: 768px) {
    .hero-image img {
        width: 7rem;
        height: 7rem;
    }
}

@media (min-width: 1024px) {
    .hero-image img {
        width: 8rem;
        height: 8rem;
    }
}

.hero-title {
    font-family: 'Noto Serif JP', serif;
    font-size: 2.25rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0;
    line-height: 1.2;
    text-align: left;
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 3rem;
    }
}

@media (min-width: 1024px) {
    .hero-title {
        font-size: 3.75rem;
    }
}

.hero-subtitle {
    font-size: 1.125rem;
    color: var(--muted-foreground);
    margin-bottom: 2rem;
    max-width: 42rem;
    margin-left: auto;
    margin-right: auto;
    animation: fade-in 0.5s ease-out 0.2s both;
}

@media (min-width: 768px) {
    .hero-subtitle {
        font-size: 1.25rem;
    }
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 4rem;
    animation: fade-in 0.5s ease-out 0.3s both;
}

@media (min-width: 640px) {
    .hero-buttons {
        flex-direction: row;
    }
}

/* Section Styles */
.section-posts {
    padding: 1rem 0 2rem;
}

.section-categories {
    padding: 4rem 0;
    background-color: rgba(241, 236, 229, 0.3);
}

.section-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.section-title {
    font-family: 'Noto Serif JP', serif;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.25rem;
}

@media (min-width: 768px) {
    .section-title {
        font-size: 1.875rem;
    }
}

.section-subtitle {
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

.section-center-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-center-header .section-title {
    margin-bottom: 0.75rem;
}

.section-center-header .section-subtitle {
    max-width: 32rem;
    margin: 0 auto;
}

.view-all-link {
    display: none;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--primary);
    transition: text-decoration 0.2s ease;
}

@media (min-width: 768px) {
    .view-all-link {
        display: inline-flex;
    }
}

.view-all-link:hover {
    text-decoration: underline;
}

.mobile-view-all {
    margin-top: 2rem;
    text-align: center;
}

@media (min-width: 768px) {
    .mobile-view-all {
        display: none;
    }
}

.mobile-view-all .view-all-link {
    display: inline-flex;
}

/* Posts Grid */
.posts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 1024px) {
    .posts-grid {
        grid-template-columns: 2fr 1fr;
    }
}

.featured-posts {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .featured-posts {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .featured-posts {
        grid-column: span 1;
    }
}

.recent-posts-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Blog Post - Featured */
.blog-post {
    transition: all 0.3s ease-out;
}

.blog-post-featured {
    position: relative;
    background-color: var(--card);
    border-radius: 0.75rem;
    border: 1px solid var(--border);
    overflow: hidden;
    cursor: pointer;
}

.blog-post-featured:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.post-image {
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, var(--japanese-red-light), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
}

.post-image-text {
    font-family: 'Noto Serif JP', serif;
    font-size: 4rem;
    color: rgba(189, 70, 49, 0.2);
}

.post-content {
    padding: 1.5rem;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.post-category {
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    background-color: var(--japanese-red-light);
    color: var(--primary);
    border-radius: 9999px;
}

.post-date {
    font-size: 0.75rem;
    color: var(--muted-foreground);
}

.post-title {
    font-family: 'Noto Serif JP', serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.5rem;
    line-height: 1.3;
    transition: color 0.2s ease;
}

.blog-post-featured:hover .post-title {
    color: var(--primary);
}

.post-excerpt {
    font-size: 0.875rem;
    color: var(--muted-foreground);
    margin-bottom: 1rem;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.post-read-time {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    color: var(--muted-foreground);
}

.post-read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--primary);
    transition: gap 0.3s ease;
}

.blog-post-featured:hover .post-read-more {
    gap: 0.5rem;
}

/* Blog Post - Compact */
.blog-post-compact {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background-color: var(--card);
    border-radius: 0.75rem;
    border: 1px solid var(--border);
    cursor: pointer;
}

.blog-post-compact:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.post-compact-image {
    width: 5rem;
    height: 5rem;
    flex-shrink: 0;
    border-radius: 0.5rem;
    background: linear-gradient(135deg, var(--japanese-red-light), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
}

.post-compact-text {
    font-family: 'Noto Serif JP', serif;
    font-size: 1.5rem;
    color: rgba(189, 70, 49, 0.3);
}

.post-compact-content {
    flex: 1;
    min-width: 0;
}

.post-compact-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.post-compact-category {
    padding: 0.125rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 500;
    background-color: var(--secondary);
    color: var(--secondary-foreground);
    border-radius: 0.25rem;
}

.post-compact-date {
    font-size: 0.75rem;
    color: var(--muted-foreground);
}

.post-compact-title {
    font-family: 'Noto Serif JP', serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.25rem;
    line-height: 1.3;
    transition: color 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.blog-post-compact:hover .post-compact-title {
    color: var(--primary);
}

.post-compact-excerpt {
    font-size: 0.875rem;
    color: var(--muted-foreground);
    line-height: 1.5;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Categories Grid */
.categories-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.category-card {
    display: block;
    padding: 1.5rem;
    background-color: var(--card);
    border-radius: 0.75rem;
    border: 1px solid var(--border);
    transition: all 0.3s ease-out;
    cursor: pointer;
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.category-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.category-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.5rem;
    background-color: var(--japanese-red-light);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
}

.category-card:hover .category-icon {
    background-color: var(--primary);
}

.category-icon svg {
    width: 1.5rem;
    height: 1.5rem;
    color: var(--primary);
    transition: color 0.3s ease;
}

.category-card:hover .category-icon svg {
    color: var(--primary-foreground);
}

.category-count {
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

.category-content {
    margin-bottom: 0.5rem;
}

.category-title {
    font-family: 'Noto Serif JP', serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--foreground);
    transition: color 0.3s ease;
}

.category-card:hover .category-title {
    color: var(--primary);
}

.category-subtitle {
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

.category-description {
    font-size: 0.875rem;
    color: var(--muted-foreground);
    line-height: 1.6;
}

/* Responsive adjustments */
@media (min-width: 1024px) {
    .recent-posts-list {
        grid-column: span 1;
    }
}
