/* Split Layout Styles for Blog-Podcast Page */

/* Search Section */
.search-section {
    padding: 4rem 0 2rem 0;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.search-bar {
    display: flex;
    max-width: 600px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.search-input {
    flex: 1;
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1rem;
    outline: none;
}

.search-input::placeholder {
    color: var(--text-secondary);
    opacity: 0.7;
}

.search-btn {
    padding: 1rem 1.5rem;
    background: var(--accent);
    border: none;
    color: white;
    cursor: pointer;
    transition: background 0.3s ease;
}

.search-btn:hover {
    background: #e55a24;
}

.split-content-section {
    padding: 1rem 0 4rem 0;
    background: var(--background);
}

.split-content-section .container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 3rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Ensure grid children don't force overflow and keep equal split */
.split-content-section .content-half {
    min-width: 0;
}

.content-half {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 2rem;
    backdrop-filter: blur(10px);
}

.section-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.section-header h2 {
    font-family: 'Cinzel', serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.section-header h2 i {
    color: var(--accent);
    font-size: 1.5rem;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1rem;
    margin: 0;
    opacity: 0.8;
}

/* Blog Grid Styles */
.blog-grid {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    min-height: 400px;
}

.blog-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.blog-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--accent);
    transform: translateY(-2px);
}

.blog-item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.blog-item h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
    line-height: 1.3;
}

.blog-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.blog-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.blog-excerpt {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.blog-tag {
    background: rgba(255, 107, 43, 0.1);
    color: var(--accent);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

.blog-author {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-style: italic;
}

/* Podcast Grid Styles */
.podcast-grid {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    min-height: 400px;
}

.podcast-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.podcast-item:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.youtube-embed {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    background: #000;
    border-radius: 8px 8px 0 0;
    overflow: hidden;
}

.youtube-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Podcast thumbnail state with click-to-play overlay */
.youtube-embed.is-thumb {
    cursor: pointer;
}

.youtube-embed.is-thumb .thumb {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.9);
    transition: filter 0.25s ease;
}

.youtube-embed.is-thumb:hover .thumb {
    filter: brightness(1);
}

.youtube-embed.is-thumb .play-overlay {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 64px;
    height: 64px;
    border-radius: 999px;
    border: none;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    display: grid;
    place-items: center;
    backdrop-filter: blur(2px);
    transition: background 0.2s ease, transform 0.2s ease;
}

.youtube-embed.is-thumb .play-overlay .play-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 999px;
    background: var(--accent);
    box-shadow: 0 6px 18px rgba(255, 107, 43, 0.35);
}

.youtube-embed.is-thumb .play-overlay i {
    margin-left: 2px;
}

.youtube-embed.is-thumb:hover .play-overlay {
    background: rgba(0, 0, 0, 0.6);
    transform: translate(-50%, -50%) scale(1.04);
}

/* Featured + Carousel layout */
.podcast-feature {
    margin-bottom: 1rem;
    display: flex;
    justify-content: flex-start;
}

.podcast-item.feature {
    width: 100%;
    max-width: min(720px, 100%);
    margin: 0;
}

.podcast-item.feature .youtube-embed {
    padding-bottom: 56.25%;
}

.podcast-carousel {
    display: block;
}

.podcast-carousel .carousel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.podcast-carousel .carousel-header h4 {
    margin: 0;
    font-family: 'Cinzel', serif;
    font-weight: 600;
    color: var(--text-primary);
}

.carousel-controls {
    display: flex;
    gap: 0.5rem;
}

.carousel-btn {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-primary);
    display: grid;
    place-items: center;
    cursor: pointer;
}

.carousel-btn:hover {
    border-color: var(--accent);
    background: rgba(255, 107, 43, 0.12);
}

.podcast-carousel .carousel-track {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 0.25rem;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.carousel-track .podcast-item.compact {
    flex: 0 0 auto;
    min-width: 260px;
    max-width: 320px;
    scroll-snap-align: start;
}

.podcast-item.compact .podcast-info {
    padding: 0.75rem;
}

.podcast-item.compact h3 {
    font-size: 1rem;
    margin: 0 0 0.25rem 0;
}

.podcast-item.compact .podcast-meta {
    gap: 0.5rem;
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
}

.podcast-item.compact .podcast-description {
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.podcast-info {
    padding: 1.5rem;
}

.podcast-info h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
    line-height: 1.3;
}

.podcast-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.podcast-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Load More Sections */
.load-more-section {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Loading and Empty States */
.loading-state, .empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-secondary);
}

.loading-state .spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 107, 43, 0.2);
    border-top: 3px solid var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.empty-state i {
    font-size: 3rem;
    color: var(--accent);
    margin-bottom: 1rem;
    opacity: 0.6;
}

.empty-state h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.5rem;
    margin: 0 0 0.5rem 0;
    color: var(--text-primary);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .split-content-section .container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .content-half {
        padding: 1.5rem;
    }
}

@media (max-width: 768px) {
    .split-content-section {
        padding: 2rem 0;
    }
    
    .split-content-section .container {
        padding: 0 1rem;
    }
    
    .content-half {
        padding: 1rem;
    }
    
    .section-header h2 {
        font-size: 1.5rem;
    }
    
    .blog-meta, .podcast-meta {
        flex-direction: column;
        gap: 0.5rem;
    }
}
