/* Premium Typography & Clean White Reset */
body {
    margin: 0;
    padding: 0;
    background-color: #ffffff; /* Premium White Background */
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: #1e293b;
    overflow-x: hidden;
}

/* Page Spacing Wrapper Layout */
.page-wrapper {
    padding: 60px 24px;
    max-width: 1200px;
    margin: 0 auto;
}

/* 1. Top Section Intro Branding Styles */
.blog-top-header {
    text-align: center;
    margin-bottom: 50px;
}

.blog-top-header h1 {
    font-size: 3rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 14px 0;
    letter-spacing: -0.04em;
}

.blog-top-header h1 .text-blue {
    color: #2563eb; /* Premium Royal Blue */
}

.blog-top-header p {
    font-size: 1.15rem;
    color: #64748b;
    max-width: 750px;
    margin: 0 auto;
    line-height: 1.6;
}

/* 2. Floating Banner Hero Box (Strict Widescreen Aspect Ratio) */
.blog-hero {
    position: relative;
    width: 100%;
    height: auto;
    aspect-ratio: 21/ 9; /* Widescreen Lock to prevent cutting */
    border-radius: 24px; /* Curved Edges */
    overflow: hidden;
    margin-bottom: 80px;
    box-shadow: 0 20px 40px -15px rgba(15, 23, 42, 0.12);
}

.hero-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(15, 23, 42, 0.9) 0%, rgba(15, 23, 42, 0.3) 100%);
    z-index: 2;
}

/* Left side typography content alignment block */
.hero-content-left {
    position: relative;
    z-index: 3;
    max-width: 580px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 50px;
    box-sizing: border-box;
}

@media (max-width: 640px) {
    .hero-content-left { padding: 0 24px; }
}

.hero-badge {
    background-color: #ef4444; /* Featured Post Alert Red */
    color: #ffffff;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    width: fit-content;
    margin-bottom: 20px;
}

.hero-content-left h2 {
    font-size: 2.6rem;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.2;
    margin: 0 0 16px 0;
    letter-spacing: -0.02em;
}

.hero-content-left p {
    font-size: 1.05rem;
    color: #cbd5e1;
    line-height: 1.6;
    margin: 0 0 28px 0;
}

.hero-btn {
    background-color: #2563eb;
    color: #ffffff;
    padding: 13px 30px;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 700;
    text-decoration: none;
    width: fit-content;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.hero-btn:hover {
    background-color: #1d4ed8;
    transform: translateY(-2px);
}

/* 3. Alternating Row Cards UI (Centered with Same left/right spacing) */
.modern-cards-list {
    display: flex;
    flex-direction: column;
    gap: 50px;
    max-width: 1000px; /* Centers the whole column layout grid layout */
    margin: 0 auto;
}

.creative-row-card {
    display: flex;
    flex-direction: column;
    background-color: #ffffff;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid #f1f5f9;
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.03);
    width: 100%;
    
    /* Scroll Animation Base Properties Structure */
    opacity: 0;
    transition: opacity 0.7s ease-out, transform 0.7s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Horizontal alignment setup for wider laptop displays */
@media (min-width: 768px) {
    .creative-row-card {
        flex-direction: row;
        height: 320px;
    }
    /* Flips direction automatically for even items */
    .creative-row-card.row-reverse {
        flex-direction: row-reverse;
    }
}

/* Sliding Offset Positions before trigger */
.creative-row-card.slide-left { transform: translateX(-50px); }
.creative-row-card.slide-right { transform: translateX(50px); }

/* Trigger visible class injected via JS intersection */
.creative-row-card.show {
    opacity: 1;
    transform: translateX(0) translateY(0);
}

/* Image Wrapper Box with Spacing Layout */
.row-card-image {
    width: 100%;
    overflow: hidden;
    padding: 16px; /* Spacing gap between card boundaries and image container box */
    box-sizing: border-box;
}

@media (min-width: 768px) {
    .row-card-image {
        width: 45%;
        height: 100%;
    }
}

.row-card-image img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    border-radius: 14px; /* Distinct Image Border Radius as requested */
    transition: transform 0.5s ease;
}

@media (min-width: 768px) {
    .row-card-image img { height: 100%; }
}

.creative-row-card:hover .row-card-image img {
    transform: scale(1.03); /* Soft image hover micro-interaction */
}

/* Text block typography area components */
.row-card-info {
    padding: 24px 32px;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

@media (min-width: 768px) {
    .row-card-info { width: 55%; }
}

/* Modern Software Category Badges */
.row-badge-category {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
    padding: 4px 12px;
    border-radius: 20px;
    width: fit-content;
}

/* Category Accent colors and background fills */
.text-blue { color: #2563eb; background-color: #eff6ff; }
.text-purple { color: #9333ea; background-color: #f3e8ff; }
.text-teal { color: #0d9488; background-color: #f0fdfa; }
.text-orange { color: #ea580c; background-color: #fff7ed; }
.text-red { color: #dc2626; background-color: #fef2f2; }
.text-green { color: #16a34a; background-color: #f0fdf4; }

.row-card-info h3 {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 10px 0;
    color: #0f172a;
}

.row-card-info p {
    font-size: 0.95rem;
    color: #64748b;
    line-height: 1.6;
    margin: 0 0 18px 0;
}

/* Blue Link Action Button elements configuration */
.card-link {
    font-size: 0.925rem;
    font-weight: 700;
    color: #2563eb;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    width: fit-content;
    transition: color 0.2s ease;
}

.card-link:hover {
    color: #1d4ed8;
    text-decoration: underline;
}


/* ==========================================================================
   MOBILE & TABLET FIX (Exact Desktop Layout Replication for Mobile)
   ========================================================================== */

/* ਮੋਬਾਈਲ ਅਤੇ ਟੈਬਲੇਟ ਦੋਵਾਂ ਲਈ (768px ਜਾਂ ਘੱਟ) */
@media (max-width: 768px) {
    
    /* 1. ਡੈਸਕਟੌਪ ਵਾਂਗ ਵਾਈਡਸਕ੍ਰੀਨ ਲੁੱਕ ਨੂੰ ਬਰਕਰਾਰ ਰੱਖਣਾ */
    .blog-hero {
        position: relative !important;
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 21 / 9 !important; /* ਇਹ ਇਮੇਜ ਨੂੰ ਬਿਲਕੁਲ ਡੈਸਕਟੌਪ ਵਾਂਗ ਚੌੜਾ ਰੱਖੇਗਾ */
        border-radius: 16px !important;    /* ਮੋਬਾਈਲ ਮੁਤਾਬਕ ਥੋੜਾ ਘੱਟ ਕਰਵਡ */
        margin-bottom: 40px !important;
    }

    .hero-bg-img {
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        z-index: 1 !important;
    }

    .hero-overlay {
        position: absolute !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100% !important;
        /* ਤੁਹਾਡਾ ਓਰੀਜਨਲ ਡੈਸਕਟੌਪ ਗ੍ਰੇਡੀਐਂਟ */
        background: linear-gradient(90deg, rgba(15, 23, 42, 0.9) 0%, rgba(15, 23, 42, 0.3) 100%) !important;
        z-index: 2 !important;
    }

    /* 2. ਟੈਕਸਟ ਨੂੰ ਖੱਬੇ ਪਾਸੇ ਹੀ ਰੱਖਣਾ (ਬਿਨਾਂ ਕਿਸੇ ਬਦਲਾਅ ਦੇ) */
    .hero-content-left {
        position: relative !important;
        z-index: 3 !important;
        height: 100% !important;
        max-width: 60% !important; /* ਟੈਕਸਟ ਨੂੰ ਸੱਜੇ ਪਾਸੇ ਦੇ ਲੋਕਾਂ ਉੱਪਰ ਜਾਣ ਤੋਂ ਰੋਕਣ ਲਈ */
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: flex-start !important;
        text-align: left !important;  /* ਖੱਬੇ ਪਾਸੇ ਅਲਾਈਨਮੈਂਟ ਲਾਕ */
        padding: 0 20px 0 30px !important; /* ਖੱਬੇ ਪਾਸੇ ਤੋਂ ਪ੍ਰੀਮੀਅਮ ਸਪੇਸ */
        box-sizing: border-box !important;
    }

    /* 3. ਸਕ੍ਰੀਨ ਦੇ ਹਿਸਾਬ ਨਾਲ ਹੈਡਿੰਗ ਦਾ ਸਾਈਜ਼ ਆਟੋ-ਐਡਜਸਟ ਕਰਨਾ */
    .hero-content-left h2 {
        font-size: 1.25rem !important; /* ਛੋਟੀ ਸਕ੍ਰੀਨ 'ਤੇ ਬਿਲਕੁਲ ਪਰਫੈਕਟ ਫਿੱਟ ਸਾਈਜ਼ */
        line-height: 1.25 !important;
        font-weight: 800 !important;
        margin: 0 0 10px 0 !important;
        letter-spacing: -0.02em !important;
    }

    /* ਮੋਬਾਈਲ 'ਤੇ ਪੈਰਾਗ੍ਰਾਫ ਨੂੰ ਛੁਪਾਉਣਾ ਜਾਂ ਬਹੁਤ ਛੋਟਾ ਕਰਨਾ ਕਿਉਂਕਿ ਜਗ੍ਹਾ ਘੱਟ ਹੁੰਦੀ ਹੈ */
    .hero-content-left p {
        display: none !important; /* ਵਾਈਡਸਕ੍ਰੀਨ ਲੁੱਕ ਵਿੱਚ ਟੈਕਸਟ ਓਵਰਫਲੋ ਰੋਕਣ ਲਈ ਪੈਰਾਗ੍ਰਾਫ ਹਟਾਇਆ */
    }

    /* 4. ਰੀਡ ਪੋਸਟ ਬਟਨ ਨੂੰ ਮੋਬਾਈਲ ਸਾਈਜ਼ ਦੇਣਾ */
    .hero-btn {
        padding: 8px 18px !important;
        font-size: 0.75rem !important;
        border-radius: 6px !important;
        width: fit-content !important;
    }
}

/* ਬਹੁਤ ਛੋਟੇ ਮੋਬਾਈਲ ਫੋਨਾਂ ਲਈ (400px ਜਾਂ ਘੱਟ) */
@media (max-width: 400px) {
    .hero-content-left {
        padding: 0 10px 0 20px !important;
    }
    .hero-content-left h2 {
        font-size: 1rem !important; /* ਹੋਰ ਛੋਟੇ ਫੋਨਾਂ ਲਈ ਸਾਈਜ਼ */
    }
    .hero-btn {
        padding: 6px 14px !important;
        font-size: 0.7rem !important;
    }
}

/* 🎯 ਨਵੇਂ ਬੈਕ ਲਿੰਕ ਲਈ ਪ੍ਰੀਮੀਅਮ ਰਿਸਪਾਂਸਿਵ CSS */
.back-to-home-link {
    color: #2563eb;
    text-decoration: underline;
    font-size: 16px;
    font-weight: 600;
    display: block;
    text-align: left;
    margin-bottom: 20px;
    width: fit-content;
    transition: color 0.2s ease;
}

.back-to-home-link:hover {
    color: #1d4ed8;
}

/* ਮੋਬਾਈਲ ਸਕ੍ਰੀਨਾਂ 'ਤੇ ਜਗ੍ਹਾ ਸਹੀ ਰੱਖਣ ਲਈ */
@media (max-width: 768px) {
    .back-to-home-link {
        font-size: 14px;
        margin-bottom: 15px;
        padding-left: 6px; /* ਮੋਬਾਈਲ 'ਤੇ ਖੱਬੇ ਪਾਸੇ ਤੋਂ ਹਲਕੀ ਸਪੇਸ */
    }
}
