* {
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    min-width: 320px;
    overflow-x: hidden;
}

.welcome-area {
    min-height: auto !important;
    height: auto !important;
}

/* HERO SECTION - FIXED */
.ai-hero {
    background: linear-gradient(135deg, #f89a59 0%, #ff8a65 100%);
    padding: clamp(100px, 15vw, 180px) 0 clamp(50px, 8vw, 80px);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.hero-title {
    color: #fff !important;
    font-size: clamp(2rem, 5vw, 3rem) !important;
    margin-bottom: clamp(1rem, 2vw, 1.5rem) !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.hero-subtitle {
    color: #fff !important;
    margin-bottom: 2rem !important;
    font-size: clamp(1rem, 2.5vw, 1.25rem) !important;
    line-height: 1.5 !important;
    font-weight: 400 !important;
    opacity: 0.95;
}

.ai-hero.blogs-hero,
.blogs-hero {
    background-image: linear-gradient(rgba(15, 23, 42, 0.7), rgba(15, 23, 42, 0.75)), url('https://res.cloudinary.com/dqz7i6r9s/image/upload/q_auto,f_auto/v1765886323/blog_ym2ylr.jpg') !important;
    background-position: center center !important;
    background-size: cover !important;
    background-repeat: no-repeat !important;
}

/* SEARCH FORM - FIXED */
.blog-search-form {
    margin-top: clamp(20px, 4vw, 30px);
}

.blog-search-form .form-group {
    display: flex;
    gap: 12px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin: 0;
}

.blog-search-form .form-control {
    width: 100%;
    max-width: 350px;
    background: rgba(255,255,255,0.95);
    border: none;
    padding: 12px 20px;
    border-radius: 25px;
    height: 46px;
    font-size: 1rem;
    transition: all 0.3s;
}

.blog-search-form .form-control:focus {
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    outline: none;
}

.blog-search-form .btn {
    background: #fff;
    color: #f89a59;
    border: none;
    padding: 12px 25px;
    border-radius: 25px;
    font-weight: 600;
    height: 46px;
    line-height: 1;
    transition: all 0.3s;
    white-space: nowrap;
    font-size: 1rem;
}

.blog-search-form .btn:hover {
    background: #1c222e;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* BLOGS SECTION */
.blogs-section {
    background: #2c3e50;
    padding: clamp(3rem, 6vw, 4rem) 0;
    min-height: 60vh;
}

/* BLOG CARDS - FIXED */
.blog-card-link {
    text-decoration: none;
    display: block;
    height: 100%;
}

.blog-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 2rem;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    height: 100%;
    display: flex;
    flex-direction: column;
    min-height: 480px;
}

.blog-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
}

/* Equal height columns */
.blogs-section .row {
    display: flex;
    flex-wrap: wrap;
}

.blogs-section [class*="col-"] {
    display: flex;
    flex-direction: column;
    margin-bottom: 2rem;
}

.blog-image {
    position: relative;
    overflow: hidden;
    height: 220px;
    background: #eee;
}

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

.blog-card:hover .blog-image img {
    transform: scale(1.05);
}

.blog-date-badge {
    position: absolute;
    top: 0;
    right: 20px;
    background: linear-gradient(135deg, #f89a59 0%, #ff8a65 100%);
    color: #fff;
    padding: 10px 16px 16px 16px;
    font-weight: 700;
    font-size: clamp(0.9rem, 1.5vw, 1rem);
    z-index: 10;
    box-shadow: 0 3px 8px rgba(248, 154, 89, 0.4);
    clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 85%, 0 100%);
}

.blog-info {
    padding: clamp(1.25rem, 2.5vw, 1.5rem);
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.blog-tags {
    color: #f89a59;
    font-size: clamp(0.75rem, 1.5vw, 0.85rem);
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    line-height: 1.4;
    letter-spacing: 0.5px;
}

.blog-title {
    color: #1c222e;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.3;
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    text-transform: none;
}

.blog-excerpt {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    flex-grow: 1;
    font-size: clamp(0.9rem, 1.5vw, 0.95rem);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    max-height: 4.8em;
}

.read-more-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: transparent;
    color: #f89a59;
    border: 2px solid #f89a59;
    border-radius: 6px;
    text-align: center;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    margin-top: 15px;
    font-size: clamp(0.9rem, 1.5vw, 1rem);
}

.read-more-btn:hover {
    background: #f89a59;
    color: #fff;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(248,154,89,0.3);
}

/* NO RESULTS */
.no-results {
    text-align: center;
    padding: clamp(40px, 8vw, 60px) 20px;
    color: #f9fafb;
}

.no-results i {
    font-size: clamp(36px, 6vw, 48px);
    color: #f89a59;
    margin-bottom: 20px;
    display: block;
}

.no-results h3 {
    font-size: clamp(1.25rem, 3vw, 1.5rem);
    margin-bottom: 10px;
    font-weight: 700;
}

.no-results p {
    font-size: clamp(0.95rem, 2vw, 1rem);
    color: #9ca3af;
    margin-bottom: 25px;
}

.no-results .btn {
    background: #f89a59;
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    text-decoration: none;
    display: inline-block;
    font-weight: 600;
    transition: all 0.3s;
    font-size: 1rem;
}

.no-results .btn:hover {
    background: #ff8a65;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(248,154,89,0.3);
}

/* =====================  RESPONSIVE  ===================== */

/* Tablet */
@media (max-width: 991px) {
    .ai-hero {
        min-height: 350px;
        padding: 90px 0 60px;
    }

    .blog-image {
        height: 200px;
    }

    .blog-card {
        margin-bottom: 1.5rem;
    }
}

/* Mobile */
@media (max-width: 767px) {
    .ai-hero {
        min-height: 300px;
        padding: 80px 0 50px;
    }

    .hero-content {
        padding: 0 15px;
    }

    .blog-search-form .form-group {
        flex-direction: column;
        gap: 12px;
        padding: 0 15px;
    }
    
    .blog-search-form .form-control {
        max-width: 100%;
        width: 100%;
    }
    
    .blog-search-form .btn {
        width: 100%;
        max-width: 250px;
    }

    .blog-image {
        height: 180px;
    }

    .blog-info {
        padding: 1.25rem;
    }

    .blog-card {
        margin-bottom: 1.5rem;
        min-height: auto;
    }

    .blogs-section {
        padding: 2.5rem 0;
    }

    .blogs-section [class*="col-"] {
        margin-bottom: 1.5rem;
    }

    .no-results {
        padding: 40px 15px;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .ai-hero {
        min-height: 280px;
        padding: 70px 0 40px;
    }

    .blog-search-form .form-control {
        padding: 10px 15px;
        height: 42px;
        font-size: 0.95rem;
    }
    
    .blog-search-form .btn {
        height: 42px;
        padding: 10px 20px;
        font-size: 0.95rem;
    }

    .blog-image {
        height: 160px;
    }

    .blog-info {
        padding: 1rem;
    }

    .blog-date-badge {
        padding: 8px 14px 14px 14px;
        right: 15px;
    }

    .read-more-btn {
        padding: 10px;
    }
}

/* Extra Small Mobile */
@media (max-width: 360px) {
    .hero-content {
        padding: 0 10px;
    }

    .blog-search-form .form-group {
        padding: 0 10px;
    }

    .blog-image {
        height: 140px;
    }
}

/* LOAD MORE BUTTON STYLES */
.load-more-container {
    text-align: center;
    margin-top: 30px;
    margin-bottom: 20px;
    width: 100%;
}

.load-more-trigger-btn {
    background: #f89a59;
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    padding: 14px 36px;
    border-radius: 30px;
    border: 2px solid #f89a59;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(248, 154, 89, 0.3);
}

.load-more-trigger-btn:hover {
    background: #e07f3c;
    border-color: #e07f3c;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(248, 154, 89, 0.4);
}

.load-more-trigger-btn i {
    font-size: 0.9rem;
    transition: transform 0.3s ease;
}

.load-more-trigger-btn:hover i {
    transform: translateY(3px);
}

.blog-item-hidden {
    display: none !important;
}

