/**
 * Blog Page Styles for Travel Royalty
 * Main layout and structure for blog listing and single post pages
 */

/* Blog Hero Section */
.blog-hero {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: white;
    padding: 8rem 0 4rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.blog-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../assets/travel_agency_hero_section.webp');
    background-size: cover;
    background-position: center;
    opacity: 0.1;
    z-index: 1;
}

.blog-hero .container {
    position: relative;
    z-index: 2;
}

#blog-header h1 {
    font-family: var(--font-family-serif, 'Playfair Display', serif);
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

#blog-header p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
}

/* Search Bar */
.blog-search {
    max-width: 600px;
    margin: 2rem auto 0;
}

.search-form {
    display: flex;
    gap: 0.5rem;
    background: white;
    border-radius: 50px;
    padding: 0.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.search-input {
    flex: 1;
    border: none;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    border-radius: 50px;
    outline: none;
}

.search-btn {
    background: linear-gradient(135deg, #d4af37 0%, #c5a028 100%);
    color: white;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.3);
}

/* Blog Content Layout */
.blog-content {
    padding: 4rem 0;
    background: #f8fafc;
}

.blog-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 3rem;
    align-items: start;
}

.blog-main {
    min-height: 400px;
}

/* Blog Grid */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

/* Featured Post (first post, full width) */
.blog-card.featured {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2rem;
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.blog-card.featured:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.blog-card.featured .card-image {
    height: 100%;
    min-height: 400px;
}

.blog-card.featured .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-card.featured .card-content {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.blog-card.featured .card-title {
    font-size: 2rem;
    margin: 1rem 0;
}

.blog-card.featured .card-excerpt {
    font-size: 1.1rem;
    line-height: 1.7;
}

/* Sidebar */
.blog-sidebar {
    position: sticky;
    top: 100px;
}

.sidebar-widget {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    margin-bottom: 2rem;
}

.sidebar-widget h3 {
    font-family: var(--font-family-serif, 'Playfair Display', serif);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #0f172a;
    border-bottom: 2px solid #d4af37;
    padding-bottom: 0.5rem;
}

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

.recent-post-item {
    display: flex;
    gap: 1rem;
    padding: 0.75rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.recent-post-item:hover {
    background: #f8fafc;
    transform: translateX(4px);
}

.recent-post-item img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
}

.recent-post-info h4 {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.recent-post-info .date {
    font-size: 0.85rem;
    color: #64748b;
}

/* Categories */
.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-list li {
    margin-bottom: 0.75rem;
}

.category-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    border-radius: 8px;
    text-decoration: none;
    color: #1e293b;
    font-weight: 500;
    transition: all 0.3s ease;
}

.category-list a:hover {
    background: #f8fafc;
    color: #d4af37;
    transform: translateX(4px);
}

.category-list .count {
    background: #f1f5f9;
    color: #64748b;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.85rem;
}

/* Tags */
.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.5rem 1rem;
    background: #f1f5f9;
    color: #475569;
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.tag:hover {
    background: #d4af37;
    color: white;
    transform: translateY(-2px);
}

.tag .count {
    background: white;
    color: #64748b;
    padding: 0.125rem 0.5rem;
    border-radius: 10px;
    font-size: 0.75rem;
}

/* Newsletter Widget */
.newsletter-widget {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: white;
}

.newsletter-widget h3 {
    color: white;
    border-bottom-color: #d4af37;
}

.newsletter-widget p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.5rem;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.newsletter-form input {
    padding: 0.75rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1rem;
}

.newsletter-form input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.newsletter-form button {
    width: 100%;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 3rem;
    padding: 2rem 0;
}

.page-btn,
.page-number {
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.page-btn {
    background: white;
    color: #0f172a;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.page-btn:hover {
    background: #d4af37;
    color: white;
    transform: translateY(-2px);
}

.page-numbers {
    display: flex;
    gap: 0.5rem;
}

.page-number {
    background: white;
    color: #64748b;
    min-width: 45px;
    justify-content: center;
}

.page-number:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.page-number.active {
    background: #d4af37;
    color: white;
}

.page-ellipsis {
    padding: 0.75rem 0.5rem;
    color: #94a3b8;
}

/* Single Post Styles */
.single-post {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.post-header {
    padding: 3rem 3rem 2rem;
    text-align: center;
}

.post-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.post-meta .category-badge {
    background: #d4af37;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.post-meta .category-badge:hover {
    background: #c5a028;
    transform: translateY(-2px);
}

.post-meta .date,
.post-meta .read-time {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #64748b;
    font-size: 0.95rem;
}

.post-title {
    font-family: var(--font-family-serif, 'Playfair Display', serif);
    font-size: 2.5rem;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.3;
    margin-bottom: 1rem;
}

.post-author {
    color: #64748b;
    font-size: 1rem;
}

.post-featured-image {
    width: 100%;
    max-height: 500px;
    overflow: hidden;
}

.post-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-content {
    padding: 3rem;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #334155;
}

.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4 {
    font-family: var(--font-family-serif, 'Playfair Display', serif);
    color: #0f172a;
    margin-top: 2rem;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.post-content h2 {
    font-size: 2rem;
    border-bottom: 2px solid #d4af37;
    padding-bottom: 0.5rem;
}

.post-content h3 {
    font-size: 1.5rem;
}

.post-content p {
    margin-bottom: 1.5rem;
}

.post-content ul,
.post-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.post-content li {
    margin-bottom: 0.75rem;
}

.post-content a {
    color: #d4af37;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.post-content a:hover {
    border-bottom-color: #d4af37;
}

.post-content strong {
    font-weight: 700;
    color: #0f172a;
}

.post-content blockquote {
    border-left: 4px solid #d4af37;
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: #475569;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 2rem 0;
}

.post-content code {
    background: #f1f5f9;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

.post-content pre {
    background: #0f172a;
    color: white;
    padding: 1.5rem;
    border-radius: 8px;
    overflow-x: auto;
    margin: 2rem 0;
}

.post-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.post-footer {
    padding: 2rem 3rem 3rem;
    border-top: 1px solid #e2e8f0;
}

.post-tags {
    margin-bottom: 2rem;
}

.post-tags strong {
    color: #0f172a;
    margin-right: 1rem;
}

.post-tags .tag {
    display: inline-flex;
    margin: 0.25rem;
}

.post-share {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.post-share strong {
    color: #0f172a;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
}

.share-btn:hover {
    transform: translateY(-3px);
}

.share-btn.facebook {
    background: #1877f2;
}

.share-btn.twitter {
    background: #1da1f2;
}

.share-btn.linkedin {
    background: #0077b5;
}

.share-btn.email {
    background: #64748b;
}

.back-to-blog {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: #f1f5f9;
    color: #0f172a;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.back-to-blog:hover {
    background: #d4af37;
    color: white;
    transform: translateX(-4px);
}

/* Empty States */
.no-posts,
.not-found {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.no-posts i,
.not-found i {
    font-size: 4rem;
    color: #d4af37;
    margin-bottom: 1rem;
}

.no-posts h3,
.not-found h2 {
    font-family: var(--font-family-serif, 'Playfair Display', serif);
    font-size: 2rem;
    color: #0f172a;
    margin-bottom: 1rem;
}

.no-posts p,
.not-found p {
    color: #64748b;
    margin-bottom: 2rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .blog-layout {
        grid-template-columns: 1fr;
    }
    
    .blog-sidebar {
        position: static;
    }
    
    .blog-card.featured {
        grid-template-columns: 1fr;
    }
    
    .blog-card.featured .card-image {
        min-height: 300px;
    }
}

@media (max-width: 768px) {
    #blog-header h1 {
        font-size: 2rem;
    }
    
    #blog-header p {
        font-size: 1rem;
    }
    
    .blog-grid {
        grid-template-columns: 1fr;
    }
    
    .post-title {
        font-size: 1.75rem;
    }
    
    .post-content {
        padding: 2rem 1.5rem;
        font-size: 1rem;
    }
    
    .post-header {
        padding: 2rem 1.5rem 1rem;
    }
    
    .post-footer {
        padding: 1.5rem;
    }
    
    .pagination {
        flex-wrap: wrap;
    }
    
    .page-numbers {
        order: -1;
        width: 100%;
        justify-content: center;
        margin-bottom: 1rem;
    }
}
