/* 
 * BharatMR Theme - Main Stylesheet
 * Dark Glassmorphism Aesthetic
 */

:root {
    --bg-color: #f3f4f6;
    --text-main: #1f2937;
    --text-muted: #4b5563;
    --accent-color: #ff2a2a; /* Bright Red */
    --accent-hover: #e01a1a;
    
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.5);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
    
    --font-heading: 'Mukta', sans-serif;
    --font-body: 'Inter', sans-serif;
    
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-body);
    margin: 0;
    padding: 0;
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    margin-top: 0;
    font-weight: 700;
    line-height: 1.2;
}

.site-main {
    padding-top: 150px;
}


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

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

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

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* Glassmorphism Utilities */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    box-shadow: var(--glass-shadow);
}

/* Typography Specific for Marathi */
.marathi-text {
    font-family: var(--font-heading);
    font-weight: 600;
}

/* Header */
.site-header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 15px 0;
    transition: all 0.3s ease;
}

.site-header.scrolled {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
    padding: 10px 0;
}

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

.logo-link {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.logo-main {
    font-size: clamp(1.4rem, 5vw, 2rem);
    font-weight: 900;
    color: #1f2937;
    letter-spacing: -1px;
}

.logo-live-badge {
    background: #ff2a2a;
    color: #fff;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 15px rgba(255, 42, 42, 0.3);
}

.live-dot {
    width: 8px;
    height: 8px;
    background: #fff;
    border-radius: 50%;
    animation: pulse-live 1.5s infinite;
}

@keyframes pulse-live {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.5); opacity: 0.5; }
    100% { transform: scale(1); opacity: 1; }
}


.main-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 20px;
}

.main-navigation a {
    color: var(--text-main);
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.1rem;
}

.main-navigation a:hover {
    color: var(--accent-color);
}

/* Ticker */
.news-ticker-wrap {
    background: var(--accent-color);
    color: #fff;
    padding: 5px 0;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
}

.ticker-label {
    background: #000;
    padding: 2px 10px;
    font-family: var(--font-heading);
    font-weight: bold;
    font-size: 0.9rem;
    z-index: 2;
    position: absolute;
    left: 0;
}

.ticker-content {
    white-space: nowrap;
    animation: tickerScroll 50s linear infinite;
    padding-left: 100%;
    padding-right: 250px; /* Space for the clock */
    font-family: var(--font-heading);
    font-size: 1rem;
}

@media (max-width: 600px) {
    .top-date-time {
        display: none; /* Hide clock on very small screens to save space */
    }
    .ticker-content {
        padding-right: 0;
    }
}


@keyframes tickerScroll {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-100%, 0, 0); }
}

/* Bento Grid */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(2, 300px);
    gap: 20px;
    margin-top: 20px; /* Reduced since site-main has padding */
    margin-bottom: 40px;
}

.bento-item {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-lg);
    cursor: pointer;
}

.bento-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.bento-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px 20px 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    z-index: 1;
}

.bento-title {
    color: #fff;
    font-size: 1.5rem;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    transition: color 0.3s ease;
}

.bento-item:hover .bento-title {
    color: var(--accent-color);
}

/* Bento Grid Spans */
.bento-item:nth-child(1) { grid-column: span 2; grid-row: span 2; }
.bento-item:nth-child(1) .bento-title { font-size: 2.2rem; }
.bento-item:nth-child(2) { grid-column: span 2; }
.bento-item:nth-child(3) { grid-column: span 1; }
.bento-item:nth-child(4) { grid-column: span 1; }

/* Single Post */
.single-post-header {
    margin-top: 10px; /* Reduced since site-main has padding */
    margin-bottom: 30px;
    text-align: center;
}

.single-title {
    font-size: clamp(1.8rem, 6vw, 3.2rem);
    margin-bottom: 20px;
    line-height: 1.2;
}

.single-thumbnail {
    width: 100% !important;
    max-width: 100% !important;
    max-height: 500px;
    height: auto !important;
    object-fit: cover;
    border-radius: var(--radius-md);
    margin-bottom: 30px;
}

.single-content img {
    max-width: 100% !important;
    height: auto !important;
    width: 100% !important;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
}

/* Affiliate Card Styles */
.affiliate-card {
    transition: transform 0.3s ease;
}
.affiliate-card:hover {
    transform: translateY(-5px);
}

@media (max-width: 600px) {
    .affiliate-card {
        flex-direction: column;
        text-align: center;
        padding: 15px !important;
    }
    .prod-img {
        flex: 0 0 100px !important;
        margin-bottom: 15px;
    }
    .amazon-btn {
        width: 100%;
        box-sizing: border-box;
    }
}

.single-content {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.15rem;
    line-height: 1.8;
}

.single-content p {
    margin-bottom: 1.5em;
}

/* Progress Bar */
.reading-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.1);
    z-index: 1001;
}

.reading-progress-bar {
    height: 100%;
    background: var(--accent-color);
    width: 0%;
}

/* Responsive */
@media (max-width: 992px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: auto;
    }
    .bento-item:nth-child(1) { grid-column: span 2; }
    .bento-item:nth-child(2) { grid-column: span 2; }
}

@media (max-width: 768px) {
    .bento-grid {
        grid-template-columns: 1fr;
    }
    .bento-item:nth-child(1), .bento-item:nth-child(2), .bento-item:nth-child(3), .bento-item:nth-child(4) {
        grid-column: span 1;
        height: 250px;
    }
    .single-title {
        font-size: 1.8rem;
    }

    /* Header Mobile Fixes */
    .header-inner {
        flex-direction: column;
        gap: 8px;
    }

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

    .main-navigation {
        width: 100%;
        overflow-x: auto;
        padding: 8px 15px !important;
        border-radius: 25px !important;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none;  /* IE and Edge */
    }

    .main-navigation::-webkit-scrollbar {
        display: none; /* Chrome, Safari and Opera */
    }

    .main-navigation ul {
        display: flex;
        flex-wrap: nowrap;
        gap: 15px;
    }

    .main-navigation a {
        font-size: 0.95rem;
        white-space: nowrap;
    }

    /* Prevent overlap - Handled by global padding */
    .site-main {
        padding-top: 140px !important;
    }


    .single-post-header {
        margin-top: 10px !important;
        margin-bottom: 20px !important;
        width: 100% !important;
        overflow: hidden;
    }
    
    .single-thumbnail {
        width: 100% !important;
        max-width: 100% !important;
    }

    .single-content.glass-panel {
        padding: 25px 15px !important;
        width: 100% !important;
        box-sizing: border-box;
    }

    .container {
        width: 95% !important;
        max-width: 100% !important;
        overflow: hidden;
    }
    
    .news-ticker-wrap {
        font-size: 0.85rem;
    }
    
    .ticker-label {
        font-size: 0.75rem;
        padding: 1px 6px;
    }
}
/* Site Footer */
.site-footer {
    padding: 60px 0;
    border-top: 1px solid var(--glass-border);
    margin-top: 60px;
    text-align: center;
}

.footer-copyright {
    display: inline-block;
    padding: 10px 30px;
    margin-top: 20px;
    max-width: 90%;
}

@media (max-width: 768px) {
    .site-footer {
        padding: 40px 0;
    }
}
