/* Blog Page Styles */

.blog-main {
    min-height: 100vh;
    padding-top: 80px;
}

/* Blog Hero Section */
.blog-hero {
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    padding: 100px 0;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.blog-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.blog-hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.blog-hero h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.blog-hero p {
    font-size: 1.3rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

.blog-search {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
    background: white;
    border-radius: 50px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.blog-search input {
    flex: 1;
    padding: 15px 25px;
    border: none;
    outline: none;
    font-size: 1rem;
    color: #333;
}

.blog-search button {
    padding: 15px 25px;
    background: #e74c3c;
    border: none;
    color: white;
    cursor: pointer;
    transition: background 0.3s ease;
}

.blog-search button:hover {
    background: #c0392b;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Blog Categories */
.blog-categories {
    padding: 80px 0;
    background: #f8f9fa;
}

.blog-categories h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
    color: #2c3e50;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.category-card {
    background: white;
    padding: 40px 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
    border-color: #3498db;
}

.category-card i {
    font-size: 3rem;
    color: #3498db;
    margin-bottom: 20px;
}

.category-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #2c3e50;
}

.category-card p {
    color: #7f8c8d;
    line-height: 1.6;
}

/* Featured Articles */
.featured-articles {
    padding: 80px 0;
}

.featured-articles h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
    color: #2c3e50;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.article-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

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

.article-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.article-card:hover .article-image img {
    transform: scale(1.1);
}

.article-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background: #3498db;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.article-content {
    padding: 25px;
}

.article-content h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: #2c3e50;
    line-height: 1.4;
}

.article-content p {
    color: #7f8c8d;
    line-height: 1.6;
    margin-bottom: 20px;
}

.article-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: #95a5a6;
}

.article-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.read-more {
    background: #3498db;
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.read-more:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

/* Knowledge Base */
.knowledge-base {
    padding: 80px 0;
    background: #f8f9fa;
}

.knowledge-base h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
    color: #2c3e50;
}

.knowledge-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.knowledge-card {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

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

.knowledge-card i {
    font-size: 2.5rem;
    color: #e74c3c;
    margin-bottom: 20px;
}

.knowledge-card h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: #2c3e50;
}

.knowledge-card ul {
    list-style: none;
    padding: 0;
}

.knowledge-card li {
    padding: 8px 0;
    color: #7f8c8d;
    position: relative;
    padding-left: 20px;
}

.knowledge-card li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #27ae60;
    font-weight: bold;
}

/* Recent Articles */
.recent-articles {
    padding: 80px 0;
}

.recent-articles h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
    color: #2c3e50;
}

.recent-list {
    max-width: 800px;
    margin: 0 auto;
}

.recent-item {
    display: flex;
    align-items: center;
    padding: 25px;
    background: white;
    margin-bottom: 20px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.recent-item:hover {
    transform: translateX(10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.recent-date {
    background: #3498db;
    color: white;
    padding: 15px;
    border-radius: 10px;
    font-weight: 600;
    text-align: center;
    min-width: 60px;
    margin-right: 25px;
}

.recent-content h4 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: #2c3e50;
}

.recent-content p {
    color: #7f8c8d;
    margin: 0;
}

/* Article Modal */
.article-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 15px;
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    animation: slideIn 0.3s ease;
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 25px;
    font-size: 2rem;
    cursor: pointer;
    color: #7f8c8d;
    z-index: 1001;
    background: white;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.modal-close:hover {
    color: #e74c3c;
}

.modal-body {
    padding: 40px;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { 
        opacity: 0;
        transform: translateY(-50px);
    }
    to { 
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Bottom Navigation */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 8px 0;
    z-index: 1000;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    display: none; /* Hidden by default, shown only on mobile */
}

.mobile-bottom-nav .nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #666;
    transition: all 0.3s ease;
    padding: 5px 10px;
    border-radius: 8px;
    min-width: 60px;
}

.mobile-bottom-nav .nav-item i {
    font-size: 20px;
    margin-bottom: 4px;
}

.mobile-bottom-nav .nav-item span {
    font-size: 12px;
    font-weight: 500;
}

.mobile-bottom-nav .nav-item.active {
    color: #007bff;
    background: rgba(0, 123, 255, 0.1);
}

.mobile-bottom-nav .nav-item:hover {
    color: #007bff;
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .mobile-bottom-nav {
        display: flex;
    }
    
    body {
        padding-bottom: 70px;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .blog-hero h1 {
        font-size: 2.5rem;
    }
    
    .blog-hero p {
        font-size: 1.1rem;
    }
    
    .blog-search {
        flex-direction: column;
        border-radius: 10px;
    }
    
    .blog-search input,
    .blog-search button {
        border-radius: 0;
    }
    
    .category-grid,
    .articles-grid,
    .knowledge-grid {
        grid-template-columns: 1fr;
    }
    
    .recent-item {
        flex-direction: column;
        text-align: center;
    }
    
    .recent-date {
        margin-right: 0;
        margin-bottom: 15px;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .modal-body {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .blog-hero {
        padding: 60px 0;
    }
    
    .blog-hero h1 {
        font-size: 2rem;
    }
    
    .featured-articles,
    .blog-categories,
    .knowledge-base,
    .recent-articles {
        padding: 40px 0;
    }
    
    .category-card,
    .knowledge-card {
        padding: 25px 20px;
    }
    
    .article-content {
        padding: 20px;
    }
}

/* Filter Animation */
.article-card.hidden {
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.3s ease;
}

.article-card.visible {
    opacity: 1;
    transform: scale(1);
    transition: all 0.3s ease;
}

/* Category Active State */
.category-card.active {
    background: #3498db;
    color: white;
    transform: translateY(-5px);
}

.category-card.active i {
    color: white;
}

.category-card.active h3 {
    color: white;
}

.category-card.active p {
    color: rgba(255,255,255,0.9);
}

/* Floating Contact Buttons */
.floating-contact-buttons {
    position: fixed;
    left: 20px;
    bottom: 100px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 999;
}

.contact-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: white;
    font-size: 24px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    animation: pulse 2s infinite;
}

.call-btn {
    background: linear-gradient(135deg, #007bff, #0056b3);
}

.whatsapp-btn {
    background: linear-gradient(135deg, #25d366, #128c7e);
}

.contact-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    animation: none;
}

@keyframes pulse {
    0% {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    }
    50% {
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    }
    100% {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    }
}

/* Mobile Bottom Navigation */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    border-top: 1px solid #e0e0e0;
    display: none;
    justify-content: space-around;
    align-items: center;
    padding: 12px 0 8px 0;
    z-index: 1000;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.mobile-bottom-nav .nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #666;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 8px 12px;
    border-radius: 12px;
    min-width: 65px;
    position: relative;
}

.mobile-bottom-nav .nav-item i {
    font-size: 22px;
    margin-bottom: 4px;
    transition: all 0.3s ease;
}

.mobile-bottom-nav .nav-item span {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mobile-bottom-nav .nav-item.active {
    color: #007bff;
    background: rgba(0, 123, 255, 0.1);
}

.mobile-bottom-nav .nav-item.active i {
    transform: scale(1.1);
    color: #007bff;
}

.mobile-bottom-nav .nav-item:hover {
    color: #007bff;
    transform: translateY(-2px);
}

.mobile-bottom-nav .nav-item:active {
    transform: translateY(0) scale(0.95);
}

/* Mobile adjustments for floating buttons */
@media (max-width: 768px) {
    .mobile-bottom-nav {
        display: flex;
    }
    
    body {
        padding-bottom: 70px;
    }
    
    .floating-contact-buttons {
        position: fixed;
        left: 15px;
        bottom: 85px; /* Above mobile bottom navigation */
        flex-direction: column;
        gap: 12px;
        z-index: 1001;
    }
    
    .contact-btn {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
}
