/*==================================================
BLOG PAGE CSS
PART 1A
Global + Hero + Search + Section Heading
==================================================*/

/*==========================
ROOT
==========================*/

:root {

    --primary: #0344a5;
    --primary-dark: #013481;
    --secondary: #1f2937;

    --bg: #f7f9fc;
    --white: #ffffff;

    --text: #232323;
    --text-light: #6b7280;

    --border: #e8edf3;

    --shadow-sm: 0 10px 30px rgba(0, 0, 0, .05);
    --shadow-md: 0 20px 45px rgba(0, 0, 0, .08);
    --shadow-lg: 0 35px 70px rgba(0, 0, 0, .12);

    --radius: 18px;
    --transition: .35s ease;

}

/*==========================
RESET
==========================*/

* {

    margin: 0;
    padding: 0;
    box-sizing: border-box;

}

html {

    scroll-behavior: smooth;

}

body {

    font-family: 'Poppins', sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;

}

img {

    max-width: 100%;
    display: block;

}

a {

    text-decoration: none;

}

.container {

    width: min(1180px, 92%);
    margin: auto;

}

section {

    position: relative;

}

/*==========================
NAVBAR SPACING
==========================*/

.header-nav {

    position: sticky;
    top: 0;
    z-index: 1000;

}

/* prevents hero hiding behind fixed navbar */

.blog-hero {

    margin-top: 0px;

}

/*==========================
BLOG HERO
==========================*/

.blog-hero {

    position: relative;

    overflow: hidden;

    padding: 110px 20px;

    background:
        linear-gradient(135deg,
            #0d6efd 0%,
            #1058c9 40%,
            #16243d 100%);

}

.blog-hero::before {

    content: "";

    position: absolute;

    inset: 0;

    background:

        radial-gradient(circle at 10% 20%,
            rgba(255, 255, 255, .08),
            transparent 40%),

        radial-gradient(circle at 90% 80%,
            rgba(255, 255, 255, .05),
            transparent 35%);

}

.blog-hero::after {

    content: "";

    position: absolute;

    width: 450px;
    height: 450px;

    right: -150px;
    top: -120px;

    border-radius: 50%;

    background:

        rgba(255, 255, 255, .04);

    filter: blur(2px);

}

.blog-hero-content {

    position: relative;

    z-index: 5;

    max-width: 760px;

    margin: auto;

    text-align: center;

    color: #fff;

}


.blog-hero h1 {

    font-size: 3.3rem;

    line-height: 1.15;

    font-weight: 700;

    margin-bottom: 28px;

}

.blog-hero p {

    font-size: 1.08rem;

    line-height: 1.9;

    opacity: .92;

    max-width: 720px;

    margin: auto;

}

.hero-buttons {

    margin-top: 42px;

}

.hero-btn {

    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 10px;

    padding: 16px 36px;

    border-radius: 60px;

    font-size: 15px;

    font-weight: 600;

    background: #fff;

    color: var(--primary);

    transition: var(--transition);

    box-shadow: 0 18px 45px rgba(0, 0, 0, .18);

}

.hero-btn:hover {

    transform: translateY(-6px);

    box-shadow: 0 25px 60px rgba(0, 0, 0, .25);

}

.hero-btn i {

    transition: .3s;

}

.hero-btn:hover i {

    transform: translateX(5px);

}

/*==========================
SEARCH
==========================*/

.blog-search-section {

    margin-top: -45px;

    position: relative;

    z-index: 10;

    padding: 0 20px;

}

.blog-search-box {

    width: min(900px, 100%);

    margin: auto;

    background: #fff;

    border-radius: 18px;

    box-shadow: var(--shadow-md);

    display: flex;

    align-items: center;

    gap: 18px;

    padding: 22px 28px;

}

.blog-search-box i {

    font-size: 20px;

    color: var(--primary);

}

.blog-search-box input {

    flex: 1;

    border: none;

    outline: none;

    background: none;

    font-family: inherit;

    font-size: 16px;

    color: var(--text);

}

.blog-search-box input::placeholder {

    color: #9ca3af;

}

/*==========================
BLOG SECTION
==========================*/

.blogs-section {

    padding: 90px 0;

}

/*==========================
SECTION TITLE
==========================*/

.section-heading {

    text-align: center;

    margin-bottom: 70px;

}

.section-heading .sub-title {

    display: inline-block;

    color: var(--primary);

    font-size: .95rem;

    font-weight: 600;

    letter-spacing: .8px;

    text-transform: uppercase;

    margin-bottom: 14px;

}

.section-heading h2 {

    font-size: 2.7rem;

    font-weight: 700;

    color: var(--secondary);

    margin-bottom: 18px;

}

.section-heading p {

    max-width: 720px;

    margin: auto;

    color: var(--text-light);

    line-height: 1.9;

    font-size: 1rem;

}

/* decorative underline */

.section-heading h2::after {

    content: "";

    display: block;

    width: 90px;

    height: 4px;

    margin: 22px auto 0;

    border-radius: 20px;

    background:

        linear-gradient(to right,
            var(--primary),
            #62b0ff);

}

/*==========================
EMPTY GRID PLACEHOLDER
(blog.js injects cards)
==========================*/

.blog-grid {

    display: grid;

    grid-template-columns:
        repeat(auto-fit,
            minmax(340px, 1fr));

    gap: 34px;

}

/*==========================
LOADING
==========================*/

.loading {

    display: flex;

    flex-direction: column;

    justify-content: center;

    align-items: center;

    padding: 80px 0;

    color: var(--text-light);

}

.loader {

    width: 58px;
    height: 58px;

    border-radius: 50%;

    border: 4px solid #dbeafe;

    border-top: 4px solid var(--primary);

    animation: spin 1s linear infinite;

    margin-bottom: 20px;

}

@keyframes spin {

    to {

        transform: rotate(360deg);

    }

}

/*==========================
ERROR
==========================*/

.error {

    display: none;

    text-align: center;

    padding: 25px;

    border-radius: 16px;

    background: #fff4f4;

    color: #d92d20;

    border: 1px solid #ffd0d0;

    margin-bottom: 35px;

    font-weight: 500;

}







/*==================================================
BLOG PAGE CSS
PART 1B
Premium Blog Cards
==================================================*/

/*==========================
BLOG GRID
==========================*/

.blog-grid {

    display: grid;

    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));

    gap: 34px;

    align-items: stretch;

}

/*==========================
BLOG CARD
(Works with cards generated by blog.js)
==========================*/

.blog-card {

    position: relative;

    display: flex;

    flex-direction: column;

    overflow: hidden;

    background: var(--white);

    border-radius: 22px;

    border: 1px solid var(--border);

    box-shadow: var(--shadow-sm);

    transition: all .35s ease;

    height: 100%;

}

.blog-card:hover {

    transform: translateY(-10px);

    box-shadow: var(--shadow-lg);

}

/*==========================
IMAGE
==========================*/

.blog-card-image {

    position: relative;

    overflow: hidden;

    height: 240px;

    background: #eef3f9;

}

.blog-card-image img {

    width: 100%;

    height: 100%;

    object-fit: cover;

    transition: transform .55s ease;

}

.blog-card:hover .blog-card-image img {

    transform: scale(1.08);

}

/* dark overlay */

.blog-card-image::after {

    content: "";

    position: absolute;

    inset: 0;

    background: linear-gradient(to top,
            rgba(0, 0, 0, .28),
            transparent 55%);

    opacity: 0;

    transition: .35s;

}

.blog-card:hover .blog-card-image::after {

    opacity: 1;

}

/*==========================
CATEGORY BADGE
==========================*/

.blog-category {

    position: absolute;

    top: 18px;

    left: 18px;

    z-index: 5;

    display: inline-flex;

    align-items: center;

    gap: 8px;

    padding: 8px 16px;

    border-radius: 100px;

    background: rgba(13, 110, 253, .95);

    color: #fff;

    font-size: 13px;

    font-weight: 600;

    letter-spacing: .3px;

    box-shadow: 0 12px 25px rgba(13, 110, 253, .25);

}

.blog-category::before {

    content: "";

    width: 7px;

    height: 7px;

    border-radius: 50%;

    background: #fff;

}

/*==========================
CARD BODY
==========================*/

.blog-card-body {

    display: flex;

    flex-direction: column;

    flex: 1;

    padding: 28px;

}

/*==========================
META
==========================*/

.blog-meta {

    display: flex;

    flex-wrap: wrap;

    gap: 18px;

    margin-bottom: 18px;

    font-size: 13px;

    color: var(--text-light);

}

.blog-meta span {

    display: flex;

    align-items: center;

    gap: 7px;

}

.blog-meta i {

    color: var(--primary);

    font-size: 13px;

}

/*==========================
TITLE
==========================*/

.blog-card h3 {

    font-size: 1.45rem;

    line-height: 1.45;

    color: var(--secondary);

    margin-bottom: 15px;

    transition: .3s;

}

.blog-card:hover h3 {

    color: var(--primary);

}

/*==========================
DESCRIPTION
==========================*/

.blog-card p {

    color: var(--text-light);

    line-height: 1.8;

    font-size: .96rem;

    margin-bottom: 26px;

    flex: 1;

}

/*==========================
READ MORE
==========================*/

.blog-readmore {

    display: inline-flex;

    align-items: center;

    gap: 10px;

    margin-top: auto;

    color: var(--primary);

    font-weight: 600;

    transition: .3s;

}

.blog-readmore i {

    transition: .3s;

}

.blog-card:hover .blog-readmore {

    color: var(--primary-dark);

}

.blog-card:hover .blog-readmore i {

    transform: translateX(6px);

}

/*==========================
BOTTOM DIVIDER
==========================*/

.blog-card-body::before {

    content: "";

    display: block;

    width: 70px;

    height: 4px;

    border-radius: 20px;

    background: linear-gradient(to right,
            var(--primary),
            #73bbff);

    margin-bottom: 22px;

}

/*==========================
FEATURED CARD
(Optional)
==========================*/

.blog-card.featured {

    border: none;

    background: linear-gradient(180deg,
            #ffffff,
            #f7fbff);

    box-shadow: 0 20px 55px rgba(0, 0, 0, .08);

}

.blog-card.featured::before {

    content: "Featured";

    position: absolute;

    top: 20px;

    right: -34px;

    transform: rotate(45deg);

    background: #ff9800;

    color: #fff;

    font-size: 12px;

    font-weight: 600;

    padding: 8px 40px;

    z-index: 10;

}

/*==========================
CARD BUTTON
(optional)
==========================*/

.blog-btn {

    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 10px;

    padding: 13px 24px;

    border-radius: 50px;

    background: var(--primary);

    color: #fff;

    font-size: 14px;

    font-weight: 600;

    transition: .3s;

}

.blog-btn:hover {

    background: var(--primary-dark);

    transform: translateY(-3px);

}

/*==========================
IMAGE PLACEHOLDER
==========================*/

.blog-placeholder {

    width: 100%;

    height: 240px;

    display: flex;

    justify-content: center;

    align-items: center;

    background: #edf2f7;

    color: #9aa4b2;

    font-size: 42px;

}

/*==========================
NO RESULTS
==========================*/

.no-results {

    grid-column: 1/-1;

    text-align: center;

    padding: 80px 30px;

    background: #fff;

    border-radius: 22px;

    border: 1px solid var(--border);

    box-shadow: var(--shadow-sm);

}

.no-results i {

    font-size: 54px;

    color: var(--primary);

    margin-bottom: 20px;

}

.no-results h3 {

    font-size: 1.8rem;

    color: var(--secondary);

    margin-bottom: 12px;

}

.no-results p {

    color: var(--text-light);

    line-height: 1.8;

    max-width: 520px;

    margin: auto;

}

/*==========================
CARD ENTRANCE ANIMATION
==========================*/

.blog-card {

    opacity: 0;

    transform: translateY(35px);

    animation: cardReveal .7s ease forwards;

}

.blog-card:nth-child(2) {

    animation-delay: .08s;

}

.blog-card:nth-child(3) {

    animation-delay: .16s;

}

.blog-card:nth-child(4) {

    animation-delay: .24s;

}

.blog-card:nth-child(5) {

    animation-delay: .32s;

}

.blog-card:nth-child(6) {

    animation-delay: .40s;

}

@keyframes cardReveal {

    to {

        opacity: 1;

        transform: translateY(0);

    }

}






/*==================================================
BLOG PAGE CSS
PART 2
Newsletter • Footer • Utilities • Responsive
==================================================*/

/*==========================
NEWSLETTER
==========================*/

.newsletter {

    padding: 90px 20px;

}

.newsletter-box {

    max-width: 1100px;

    margin: auto;

    background: linear-gradient(135deg,
            #0d6efd,
            #163c82);

    border-radius: 28px;

    padding: 70px 50px;

    text-align: center;

    color: #fff;

    overflow: hidden;

    position: relative;

}

.newsletter-box::before {

    content: "";

    position: absolute;

    width: 350px;

    height: 350px;

    background: rgba(255, 255, 255, .06);

    border-radius: 50%;

    top: -180px;

    right: -120px;

}

.newsletter-box::after {

    content: "";

    position: absolute;

    width: 250px;

    height: 250px;

    background: rgba(255, 255, 255, .05);

    border-radius: 50%;

    bottom: -120px;

    left: -80px;

}

.newsletter-box>* {

    position: relative;

    z-index: 2;

}

.newsletter-box span {

    display: inline-block;

    margin-bottom: 18px;

    padding: 8px 18px;

    border-radius: 40px;

    background: rgba(255, 255, 255, .15);

    font-size: .9rem;

    font-weight: 600;

}

.newsletter-box h2 {

    font-size: 2.5rem;

    margin-bottom: 20px;

}

.newsletter-box p {

    max-width: 650px;

    margin: auto;

    line-height: 1.9;

    opacity: .92;

}

.newsletter-box form {

    margin-top: 40px;

    display: flex;

    justify-content: center;

    gap: 18px;

    flex-wrap: wrap;

}

.newsletter-box input {

    width: 420px;

    max-width: 100%;

    padding: 18px 24px;

    border: none;

    outline: none;

    border-radius: 60px;

    font-family: inherit;

    font-size: 15px;

}

.newsletter-box button {

    padding: 18px 34px;

    border: none;

    border-radius: 60px;

    background: #fff;

    color: var(--primary);

    font-weight: 600;

    cursor: pointer;

    transition: .35s;

}

.newsletter-box button:hover {

    transform: translateY(-4px);

    box-shadow: 0 20px 40px rgba(0, 0, 0, .18);

}

/*==========================
FOOTER
==========================*/

footer {

    margin-top: 80px;

}

/*==========================
SCROLLBAR
==========================*/

::-webkit-scrollbar {

    width: 10px;

}

::-webkit-scrollbar-track {

    background: #eef2f7;

}

::-webkit-scrollbar-thumb {

    background: #b6c2d0;

    border-radius: 50px;

}

::-webkit-scrollbar-thumb:hover {

    background: #8da2bb;

}

/*==========================
TEXT SELECTION
==========================*/

::selection {

    background: var(--primary);

    color: #fff;

}

/*==========================
UTILITY
==========================*/

.text-center {

    text-align: center;

}

.mt-2 {

    margin-top: 20px;

}

.mt-3 {

    margin-top: 30px;

}

.mt-4 {

    margin-top: 40px;

}

/*==========================
SMOOTH IMAGE HOVER
==========================*/

img {

    transition: .35s;

}

/*==========================
FADE ANIMATION
==========================*/

.fade-up {

    animation: fadeUp .8s ease;

}

@keyframes fadeUp {

    from {

        opacity: 0;

        transform: translateY(40px);

    }

    to {

        opacity: 1;

        transform: translateY(0);

    }

}

/*==========================
RESPONSIVE
==========================*/

@media(max-width:1100px) {

    .blog-hero h1 {

        font-size: 2.9rem;

    }

    .section-heading h2 {

        font-size: 2.3rem;

    }

    .blog-grid {

        grid-template-columns: repeat(2, 1fr);

    }

}

@media(max-width:900px) {

    .blog-hero {

        padding: 90px 25px;

    }

    .blog-hero h1 {

        font-size: 2.4rem;

    }

    .blog-search-box {

        padding: 18px 20px;

    }

    .newsletter-box {

        padding: 60px 35px;

    }

    .newsletter-box h2 {

        font-size: 2rem;

    }

    .blog-grid {

        gap: 24px;

    }

}

@media(max-width:768px) {

    .blog-hero {

        margin-top: 65px;

        padding: 80px 20px;

    }

    .blog-hero h1 {

        font-size: 2rem;

    }

    .blog-hero p {

        font-size: .96rem;

    }

    .hero-btn {

        width: 100%;

    }

    .blog-search-section {

        margin-top: -30px;

    }

    .blog-search-box {

        border-radius: 16px;

    }

    .blog-grid {

        grid-template-columns: 1fr;

    }

    .section-heading {

        margin-bottom: 50px;

    }

    .section-heading h2 {

        font-size: 2rem;

    }

    .newsletter {

        padding: 70px 20px;

    }

    .newsletter-box {

        padding: 50px 25px;

    }

    .newsletter-box h2 {

        font-size: 1.8rem;

    }

    .newsletter-box form {

        flex-direction: column;

    }

    .newsletter-box input {

        width: 100%;

    }

    .newsletter-box button {

        width: 100%;

    }

}

@media(max-width:576px) {

    .blog-hero {

        padding: 70px 18px;

    }

    .hero-tag {

        font-size: .8rem;

    }

    .blog-hero h1 {

        font-size: 1.75rem;

    }

    .blog-search-box {

        padding: 16px 18px;

    }

    .blog-search-box input {

        font-size: 14px;

    }

    .blog-card-image {

        height: 220px;

    }

    .blog-card-body {

        padding: 22px;

    }

    .blog-card h3 {

        font-size: 1.25rem;

    }

    .blog-card p {

        font-size: .92rem;

    }

    .newsletter-box h2 {

        font-size: 1.6rem;

    }

    .newsletter-box p {

        font-size: .92rem;

    }

    .loading {

        padding: 60px 0;

    }

    .loader {

        width: 48px;

        height: 48px;

    }

}

@media(max-width:380px) {

    .blog-hero h1 {

        font-size: 1.5rem;

    }

    .blog-card-body {

        padding: 20px;

    }

    .hero-btn {

        padding: 14px 24px;

    }

    .newsletter-box {

        border-radius: 20px;

    }

}

/*==========================
END
==========================*/