/* Base Header Styles (Desktop) */
#masthead, .site-header, header {
    background-color: #f7f3ee !important;
    box-sizing: border-box; /* Prevents padding/border from causing overflow */
}

.site-header, header {
    background-color: #f7f3ee !important; 
    padding: 20px;                        
    border: 5px solid #FFFFFF;            
    box-shadow: 0 0 0 15px #FFFFFF;       
    margin: 15px;
    max-width: 100%;
    width: 100%;
    
    margin-top: 15px !important;
    margin-bottom: 15px !important;
    margin-left: 15px;
    margin-right: 15px;
}

/* ✅ Mobile Optimization (< 768px) */
@media (max-width: 767px) {
    .site-header, header {
        padding: 16px 12px;
        border: 3px solid #FFFFFF;
        box-shadow: 0 0 0 8px #FFFFFF;   /* Reduced frame to save screen space */
        margin: 10px 6px !important;     /* Tighter side margins to prevent horizontal scroll */
        margin-top: 12px !important;
        margin-bottom: 12px !important;
        overflow: hidden;                /* Safety net for any stray elements */
    }
}
.blog-section-drameen {
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.blog-section-drameen .section-header {
    text-align: center;
    margin-bottom: 60px;
}

.blog-section-drameen .section-header h2 {
    font-size: 2.5rem;
    color: #1a4d5c;
    margin-bottom: 15px;
    font-weight: 700;
    position: relative;
    display: inline-block;
}

.blog-section-drameen .section-header h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #2a9d8f, #264653);
    border-radius: 2px;
}

.blog-section-drameen .section-header p {
    color: #5a7d8c;
    font-size: 1.1rem;
    margin-top: 20px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.blog-section-drameen .blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 35px;
    margin-bottom: 50px;
}

.blog-section-drameen .blog-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(42, 157, 143, 0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(255, 255, 255, 0.3);
    position: relative;
}

.blog-section-drameen .blog-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #2a9d8f, #264653);
    transform: scaleX(0);
    transition: transform 0.4s ease;
    z-index: 1;
}

.blog-section-drameen .blog-card:hover::before {
    transform: scaleX(1);
}

.blog-section-drameen .blog-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 16px 48px rgba(42, 157, 143, 0.2);
}

.blog-section-drameen .card-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    background: linear-gradient(135deg, #2a9d8f 0%, #264653 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.3);
}

.blog-section-drameen .card-content {
    padding: 28px;
}

.blog-section-drameen .card-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.blog-section-drameen .category-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: linear-gradient(135deg, #2a9d8f, #264653);
    color: white;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.blog-section-drameen .category-badge.ear {
    background: linear-gradient(135deg, #e76f51, #f4a261);
}

.blog-section-drameen .category-badge.nose {
    background: linear-gradient(135deg, #2a9d8f, #264653);
}

.blog-section-drameen .category-badge.throat {
    background: linear-gradient(135deg, #e9c46a, #f4a261);
}

.blog-section-drameen .category-badge.sleep {
    background: linear-gradient(135deg, #457b9d, #1d3557);
}

.blog-section-drameen .card-date {
    color: #6c757d;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.blog-section-drameen .reading-time {
    color: #2a9d8f;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
}

.blog-section-drameen .card-title {
    font-size: 1.4rem;
    color: #1a4d5c;
    margin-bottom: 12px;
    font-weight: 700;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.blog-section-drameen .blog-card:hover .card-title {
    color: #2a9d8f;
}

.blog-section-drameen .card-excerpt {
    color: #5a7d8c;
    line-height: 1.7;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.blog-section-drameen .read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #2a9d8f;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.blog-section-drameen .read-more:hover {
    gap: 12px;
    color: #264653;
}

.blog-section-drameen .read-more::after {
    content: '→';
    transition: transform 0.3s ease;
}

.blog-section-drameen .read-more:hover::after {
    transform: translateX(4px);
}

.blog-section-drameen .view-all-btn {
    text-align: center;
    margin-top: 40px;
}

.blog-section-drameen .view-all-btn a {
    display: inline-block;
    padding: 15px 40px;
    background: linear-gradient(135deg, #2a9d8f, #264653);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(42, 157, 143, 0.3);
}

.blog-section-drameen .view-all-btn a:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(42, 157, 143, 0.4);
}

@media (max-width: 768px) {
    .blog-section-drameen .section-header h2 {
        font-size: 2rem;
    }

    .blog-section-drameen .blog-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .blog-section-drameen .card-content {
        padding: 22px;
    }
}