/*
Theme Name: Modern Bangla News Pro
Theme URI: https://example.com/bangla-news-pro
Author: Theme Developer
Author URI: https://example.com
Description: Ultra-fast, modern, SEO-optimized WordPress newspaper theme for Bangla news websites. Features include mega menu, social sharing, related posts, ad management, lazy loading, and mobile-first responsive design.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: bangla-news-pro
Tags: news, magazine, blog, bangla, bengali, rtl-language-support, responsive-layout, custom-menu, featured-images, threaded-comments, translation-ready, custom-colors, editor-style, sticky-post, microformats
*/

/* CSS Variables for Easy Customization */
:root {
    --primary-color: #e74c3c;
    --secondary-color: #2c3e50;
    --accent-color: #3498db;
    --text-color: #333;
    --light-bg: #f8f9fa;
    --border-color: #ddd;
    --white: #ffffff;
    --shadow: 0 2px 8px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
    --font-bangla: 'Noto Sans Bengali', 'Kalpurush', sans-serif;
    --font-english: 'Roboto', sans-serif;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-bangla);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color);
    background: var(--white);
    overflow-x: hidden;
}

a {
    color: var(--text-color);
    text-decoration: none;
    transition: var(--transition);
}

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

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

/* Top Header Bar */
.top-header {
    background: var(--secondary-color);
    color: var(--white);
    padding: 8px 0;
    font-size: 14px;
}

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

.date-time {
    display: flex;
    align-items: center;
    gap: 15px;
}

.social-links {
    display: flex;
    gap: 12px;
}

.social-links a {
    color: var(--white);
    font-size: 16px;
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--primary-color);
    transform: scale(1.1);
}

/* Main Header */
.main-header {
    background: var(--white);
    padding: 20px 0;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

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

.site-logo img {
    max-height: 60px;
}

.header-ad {
    flex: 1;
    text-align: center;
    max-width: 728px;
    margin: 0 20px;
}

.search-social {
    display: flex;
    align-items: center;
    gap: 15px;
}

.search-form {
    position: relative;
}

.search-form input {
    padding: 10px 40px 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: 25px;
    width: 250px;
    font-family: var(--font-bangla);
}

.search-form button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 8px 15px;
    border-radius: 20px;
    cursor: pointer;
}

/* Navigation Menu */
.main-navigation {
    background: var(--primary-color);
    box-shadow: var(--shadow);
}

.nav-menu {
    display: flex;
    list-style: none;
    flex-wrap: wrap;
}

.nav-menu > li {
    position: relative;
}

.nav-menu > li > a {
    display: block;
    padding: 15px 20px;
    color: var(--white);
    font-weight: 500;
    transition: var(--transition);
}

.nav-menu > li > a:hover,
.nav-menu > li.current-menu-item > a {
    background: rgba(0,0,0,0.2);
}

/* Dropdown Menu */
.nav-menu .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--white);
    min-width: 220px;
    box-shadow: var(--shadow);
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition);
    z-index: 100;
}

.nav-menu li:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-menu .sub-menu li a {
    display: block;
    padding: 12px 20px;
    color: var(--text-color);
    border-bottom: 1px solid var(--border-color);
}

.nav-menu .sub-menu li a:hover {
    background: var(--light-bg);
    padding-left: 25px;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 10px 20px;
    font-size: 18px;
    cursor: pointer;
}

/* Breaking News Ticker */
.breaking-news {
    background: var(--secondary-color);
    color: var(--white);
    padding: 12px 0;
    overflow: hidden;
}

.breaking-news .container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.breaking-label {
    background: var(--primary-color);
    padding: 5px 15px;
    font-weight: bold;
    white-space: nowrap;
}

.news-ticker {
    flex: 1;
    overflow: hidden;
}

.ticker-content {
    display: flex;
    animation: scroll 30s linear infinite;
}

.ticker-content:hover {
    animation-play-state: paused;
}

.ticker-item {
    padding: 0 30px;
    white-space: nowrap;
    color: var(--white);
}

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Main Content Area */
.content-wrapper {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
    margin: 30px auto;
}

/* Featured News Section */
.featured-section {
    margin-bottom: 30px;
}

.featured-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

.featured-main {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.featured-main img {
    width: 100%;
    height: 450px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.featured-main:hover img {
    transform: scale(1.05);
}

.featured-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: var(--white);
    padding: 30px;
}

.featured-content .category {
    background: var(--primary-color);
    display: inline-block;
    padding: 5px 12px;
    font-size: 12px;
    font-weight: bold;
    margin-bottom: 10px;
    border-radius: 3px;
}

.featured-content h2 {
    font-size: 28px;
    line-height: 1.3;
    margin-bottom: 10px;
}

.featured-content .meta {
    font-size: 14px;
    opacity: 0.9;
}

.featured-side {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.side-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    height: 142px;
}

.side-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.side-item:hover img {
    transform: scale(1.05);
}

.side-item .overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: var(--white);
    padding: 15px;
}

.side-item h3 {
    font-size: 16px;
    line-height: 1.3;
}

/* Section Title */
.section-title {
    border-left: 4px solid var(--primary-color);
    padding-left: 15px;
    margin-bottom: 20px;
    font-size: 24px;
    font-weight: bold;
    color: var(--secondary-color);
}

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    margin-bottom: 40px;
}

.news-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.news-card .thumbnail {
    position: relative;
    overflow: hidden;
    height: 200px;
}

.news-card .thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-card:hover .thumbnail img {
    transform: scale(1.1);
}

.news-card .category-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--primary-color);
    color: var(--white);
    padding: 5px 12px;
    font-size: 11px;
    font-weight: bold;
    border-radius: 3px;
}

.news-card .content {
    padding: 20px;
}

.news-card h3 {
    font-size: 18px;
    line-height: 1.4;
    margin-bottom: 10px;
    font-weight: 600;
}

.news-card .excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
    margin-bottom: 12px;
}

.news-card .meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #999;
    border-top: 1px solid var(--border-color);
    padding-top: 12px;
}

/* Sidebar */
.sidebar {
    position: sticky;
    top: 150px;
}

.widget {
    background: var(--white);
    padding: 25px;
    margin-bottom: 25px;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.widget-title {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 3px solid var(--primary-color);
    color: var(--secondary-color);
}

.popular-list li {
    list-style: none;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    gap: 15px;
}

.popular-list li:last-child {
    border-bottom: none;
}

.popular-list .thumbnail {
    width: 80px;
    height: 60px;
    flex-shrink: 0;
    border-radius: 5px;
    overflow: hidden;
}

.popular-list .thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.popular-list .details h4 {
    font-size: 15px;
    line-height: 1.4;
    margin-bottom: 5px;
}

.popular-list .details .date {
    font-size: 12px;
    color: #999;
}

/* Ad Widget */
.ad-widget {
    text-align: center;
    background: var(--light-bg);
    padding: 15px;
    border: 1px dashed var(--border-color);
}

/* Social Share Buttons */
.share-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin: 20px 0;
}

.share-btn {
    padding: 10px 20px;
    border-radius: 5px;
    color: var(--white);
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.share-facebook { background: #3b5998; }
.share-twitter { background: #1da1f2; }
.share-whatsapp { background: #25d366; }
.share-linkedin { background: #0077b5; }
.share-telegram { background: #0088cc; }

/* Related Posts */
.related-posts {
    margin: 40px 0;
    padding: 30px;
    background: var(--light-bg);
    border-radius: 8px;
}

.related-posts h3 {
    font-size: 24px;
    margin-bottom: 25px;
    color: var(--secondary-color);
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* Footer */
.site-footer {
    background: var(--secondary-color);
    color: var(--white);
    padding: 50px 0 20px;
    margin-top: 50px;
}

.footer-widgets {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 40px;
}

.footer-widget h3 {
    font-size: 20px;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-color);
}

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

.footer-widget ul li {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-widget ul li a {
    color: rgba(255,255,255,0.8);
}

.footer-widget ul li a:hover {
    color: var(--white);
    padding-left: 5px;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 14px;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin: 40px 0;
}

.pagination a,
.pagination span {
    padding: 10px 15px;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 5px;
    transition: var(--transition);
}

.pagination a:hover,
.pagination .current {
    background: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
}

/* Comments Section */
.comments-area {
    margin: 40px 0;
    padding: 30px;
    background: var(--light-bg);
    border-radius: 8px;
}

.comment-list {
    list-style: none;
}

.comment {
    padding: 20px;
    background: var(--white);
    margin-bottom: 15px;
    border-radius: 8px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .content-wrapper {
        grid-template-columns: 1fr 280px;
    }
    
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-widgets {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .top-header .container {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .header-content {
        flex-direction: column;
        gap: 15px;
    }
    
    .header-ad {
        margin: 15px 0;
    }
    
    .search-form input {
        width: 100%;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .nav-menu {
        display: none;
        flex-direction: column;
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .nav-menu > li > a {
        padding: 12px 15px;
    }
    
    .nav-menu .sub-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border-top: 1px solid rgba(255,255,255,0.1);
    }
    
    .featured-grid {
        grid-template-columns: 1fr;
    }
    
    .content-wrapper {
        grid-template-columns: 1fr;
    }
    
    .news-grid {
        grid-template-columns: 1fr;
    }
    
    .related-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-widgets {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        position: static;
    }
}

/* Loading Animation */
.loading {
    text-align: center;
    padding: 20px;
}

.spinner {
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Lazy Load Placeholder */
img[data-src] {
    background: var(--light-bg);
    min-height: 200px;
}

/* Print Styles */
@media print {
    .top-header,
    .main-navigation,
    .breaking-news,
    .sidebar,
    .site-footer,
    .share-buttons {
        display: none;
    }
}
