/* ─── MarketGift Blog Premium Theme: Minimalist & Clean ─── */

:root {
    --font-heading: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
    background-color: #f8fafd !important;
}

/* ── MAIN WRAPPER ── */
.blog-main { 
    background-image: radial-gradient(rgba(0, 71, 171, 0.035) 1.5px, transparent 1.5px);
    background-size: 24px 24px;
    padding-top: 50px;
    padding-bottom: 90px; 
}

/* ── HERO ── */
.blog-hero {
    background: linear-gradient(135deg, #07090e 0%, #0047ab 65%, #0284c7 100%);
    padding: 65px 0 60px;
    margin-bottom: 55px;
    position: relative;
    overflow: hidden;
}

.blog-hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(circle at 75% 20%, rgba(255,255,255,0.04) 0%, transparent 60%);
    pointer-events: none;
}

.blog-hero .esp-bre .breadcrumb-item a,
.blog-hero .esp-bre .breadcrumb-item.active,
.blog-hero .b-esp { 
    color: rgba(255, 255, 255, 0.72) !important; 
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 500;
}

.blog-hero-title {
    font-family: var(--font-heading);
    font-size: clamp(2.1rem, 3.8vw, 3rem);
    font-weight: 700;
    color: #ffffff;
    margin: 16px 0 10px;
    letter-spacing: -0.03em;
}

.blog-hero-sub {
    font-family: var(--font-body);
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.05rem;
    font-weight: 400;
    margin-bottom: 0;
    max-width: 620px;
    line-height: 1.55;
}

/* ── CATEGORY PILLS ── */
.blog-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.blog-cat-pill {
    display: inline-flex;
    align-items: center;
    padding: 6px 16px;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(8px);
}

.blog-cat-pill:hover,
.blog-cat-pill.active {
    background: #ffffff;
    color: #0047ab;
    border-color: #ffffff;
    transform: translateY(-1.5px);
    box-shadow: 0 8px 18px rgba(255, 255, 255, 0.12);
}

/* ── FEATURED CARD ── */
.blog-card-featured {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    border-radius: 20px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 10px 35px rgba(0, 71, 171, 0.04);
    border: 1px solid #edf2f7;
    text-decoration: none;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.blog-card-featured:hover {
    transform: translateY(-5px);
    box-shadow: 0 18px 45px rgba(0, 71, 171, 0.09);
    border-color: rgba(0, 71, 171, 0.1);
}

.blog-card-featured-img-container {
    overflow: hidden;
    position: relative;
}

.blog-card-featured-img {
    background-size: cover;
    background-position: center;
    width: 100%;
    height: 100%;
    min-height: 360px;
    transition: transform 0.5s ease;
}

.blog-card-featured:hover .blog-card-featured-img {
    transform: scale(1.025);
}

.blog-card-featured-body {
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.blog-badge-wrapper {
    display: flex;
    gap: 8px;
}

.blog-card-featured-title {
    font-family: var(--font-heading);
    font-size: clamp(1.35rem, 2.2vw, 1.7rem);
    font-weight: 700;
    color: #0f172a;
    margin: 12px 0 12px;
    line-height: 1.3;
    letter-spacing: -0.025em;
}

.blog-card-featured-excerpt {
    font-family: var(--font-body);
    color: #475569;
    font-size: 0.9rem;
    font-weight: 400;
    line-height: 1.65;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── REGULAR CARD ── */
.blog-card {
    display: flex;
    flex-direction: column;
    border-radius: 18px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.02);
    border: 1px solid #edf2f7;
    text-decoration: none;
    height: 100%;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.blog-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 35px rgba(0, 71, 171, 0.07);
    border-color: rgba(0, 71, 171, 0.15);
}

.blog-card-img-wrap {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: #f8fafc;
}

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

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

.blog-card-body {
    padding: 22px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.blog-card-title {
    font-family: var(--font-heading);
    font-size: 0.98rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 8px;
    line-height: 1.35;
    letter-spacing: -0.02em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-card-excerpt {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 400;
    color: #64748b;
    line-height: 1.55;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 16px;
}

/* ── BADGES ── */
.blog-cat-tag {
    display: inline-block;
    background: #eff6ff;
    color: #0047ab;
    border: 1px solid #dbeafe;
    border-radius: 50px;
    padding: 3px 10px;
    font-family: var(--font-heading);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.blog-ai-tag {
    display: inline-block;
    background: #faf5ff;
    color: #7c3aed;
    border: 1px solid #e9d5ff;
    border-radius: 50px;
    padding: 3px 10px;
    font-family: var(--font-heading);
    font-size: 0.7rem;
    font-weight: 700;
}

/* ── META ── */
.blog-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-body);
    font-size: 0.76rem;
    font-weight: 500;
    color: #94a3b8;
    gap: 8px;
    flex-wrap: wrap;
    border-top: 1px solid #f1f5f9;
    padding-top: 12px;
    margin-top: auto;
}

.blog-card-meta i { 
    margin-right: 4px; 
}

.blog-read-more {
    color: #0047ab;
    font-weight: 700;
    font-family: var(--font-heading);
    font-size: 0.78rem;
    display: flex;
    align-items: center;
    gap: 4px;
}

.blog-read-more i {
    transition: transform 0.2s ease;
}

.blog-card:hover .blog-read-more i {
    transform: translateX(3px);
}

/* ── EMPTY STATE ── */
.blog-empty {
    text-align: center;
    padding: 90px 24px;
}

.blog-empty i { 
    font-size: 3.5rem; 
    color: #cbd5e1; 
    margin-bottom: 16px; 
    display: block; 
}

.blog-empty p { 
    font-family: var(--font-body); 
    color: #64748b; 
    font-size: 1.05rem;
    margin-bottom: 20px; 
}

/* ── PAGINATION ── */
.blog-pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 55px;
    flex-wrap: wrap;
}

.blog-page-btn {
    width: 40px; height: 40px;
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--font-heading);
    font-size: 0.88rem;
    font-weight: 600;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    color: #475569;
    text-decoration: none;
    transition: all 0.2s ease;
}

.blog-page-btn:hover,
.blog-page-btn.active {
    background: #0047ab;
    border-color: #0047ab;
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(0, 71, 171, 0.15);
}

/* ── BUTTONS ── */
.blog-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #0047ab 0%, #3b82f6 100%);
    color: #ffffff !important;
    padding: 12px 24px;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 5px 15px rgba(0, 71, 171, 0.2);
}

.blog-btn-primary:hover {
    transform: translateY(-2.5px);
    box-shadow: 0 8px 20px rgba(0, 71, 171, 0.3);
}

.blog-btn-back {
    font-family: var(--font-heading);
    font-size: 0.88rem;
    font-weight: 700;
    color: #0047ab;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s ease;
}

.blog-btn-back:hover { 
    color: #3b82f6; 
}

/* ── POST HERO ── */
.post-hero {
    position: relative;
    background: linear-gradient(135deg, #07090e 0%, #0047ab 65%, #0284c7 100%);
    padding: 70px 0 65px;
    margin-bottom: 55px;
    overflow: hidden;
}

.post-hero-img {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    z-index: 0;
}

.post-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(7, 9, 14, 0.92) 0%, rgba(0, 71, 171, 0.84) 65%, rgba(2, 132, 199, 0.68) 100%);
}

.post-hero-body { 
    position: relative; 
    z-index: 1; 
}

.post-title {
    font-family: var(--font-heading);
    font-size: clamp(1.7rem, 3.8vw, 2.6rem);
    font-weight: 700;
    color: #ffffff;
    line-height: 1.25;
    margin: 16px 0 16px;
    max-width: 800px;
    letter-spacing: -0.03em;
}

.post-meta {
    display: flex;
    gap: 20px;
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.72);
    flex-wrap: wrap;
}

.post-meta i { 
    margin-right: 5px; 
}

/* ── POST READING CARD ── */
.post-reading-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 50px 55px;
    border: 1px solid #edf2f7;
    box-shadow: 0 20px 45px rgba(0, 71, 171, 0.03);
    margin-top: -75px;
    position: relative;
    z-index: 10;
}

/* ── POST BODY ── */
.post-excerpt {
    font-family: var(--font-body);
    font-size: 1.15rem;
    font-weight: 400;
    color: #475569;
    line-height: 1.7;
    border-left: 3px solid #3b82f6;
    padding-left: 20px;
    margin-bottom: 35px;
    font-style: italic;
}

.post-body {
    font-family: var(--font-body);
    font-size: 1.02rem;
    font-weight: 400;
    color: #334155;
    line-height: 1.85;
    max-width: 100%;
}

.post-body h2 {
    font-family: var(--font-heading);
    font-size: 1.45rem;
    font-weight: 700;
    color: #0f172a;
    margin: 42px 0 16px;
    letter-spacing: -0.025em;
}

.post-body h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    color: #1e293b;
    margin: 32px 0 10px;
    letter-spacing: -0.02em;
}

.post-body p { 
    margin-bottom: 20px; 
}

.post-body ul, .post-body ol {
    margin-bottom: 22px;
    padding-left: 24px;
}

.post-body li { 
    margin-bottom: 6px; 
}

.post-body strong { 
    color: #0f172a; 
    font-weight: 600;
}

.post-body a { 
    color: #0047ab; 
    font-weight: 500;
    text-decoration: underline;
}

.post-body a:hover { 
    color: #3b82f6; 
}

.post-body img {
    max-width: 100%;
    border-radius: 12px;
    margin: 20px 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
}

/* ── AUTHOR BOX ── */
.post-author-box {
    display: flex;
    align-items: center;
    gap: 20px;
    background: #f8fafc;
    border: 1px solid rgba(0, 71, 171, 0.04);
    border-radius: 20px;
    padding: 24px 28px;
    margin: 45px 0 35px;
}

.author-avatar-wrap {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0047ab 0%, #3b82f6 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 71, 171, 0.12);
}

.author-initials {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.05em;
}

.author-info {
    flex-grow: 1;
}

.author-name {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 4px;
}

.author-bio {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 400;
    color: #475569;
    margin: 0;
    line-height: 1.45;
}

/* ── POST CTA ── */
.post-cta {
    background: #f0f7ff;
    border: 1px solid rgba(0, 71, 171, 0.06);
    border-radius: 24px;
    padding: 40px;
    margin: 60px 0 30px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 71, 171, 0.02);
}

.post-cta-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    color: #0047ab;
    margin-bottom: 8px;
    letter-spacing: -0.02em;
}

.post-cta-sub {
    font-family: var(--font-body);
    font-size: 0.88rem;
    font-weight: 400;
    color: #475569;
    margin-bottom: 24px;
    line-height: 1.5;
}

/* ─── SIDEBAR & WIDGETS ─── */
.blog-sidebar {
    position: sticky;
    top: 24px;
}

.sidebar-widget {
    background: #ffffff;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #edf2f7;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.015);
}

.widget-title {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 14px;
    border-left: 3px solid #0047ab;
    padding-left: 8px;
    letter-spacing: -0.015em;
}

/* ── SEARCH WIDGET ── */
.sidebar-search-form {
    position: relative;
    display: flex;
}

.sidebar-search-input {
    border-radius: 50px !important;
    padding: 8px 40px 8px 16px !important;
    font-family: var(--font-body) !important;
    font-size: 0.82rem !important;
    border: 1px solid #cbd5e1 !important;
    background: #ffffff !important;
}

.sidebar-search-btn {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: #64748b;
    padding: 6px;
    transition: color 0.2s ease;
    cursor: pointer;
}

.sidebar-search-btn:hover {
    color: #0047ab;
}

/* ── SIDEBAR CATEGORIES ── */
.sidebar-cat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    background: #f8fafc;
    border: 1px solid #edf2f7;
    border-radius: 10px;
    color: #475569;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    margin-bottom: 6px;
    transition: all 0.2s ease;
}

.sidebar-cat-item:hover,
.sidebar-cat-item.active {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #0047ab;
    transform: translateX(3px);
}

/* ── SIDEBAR STORES ── */
.sidebar-stores-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.sidebar-store-card {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f8fafc;
    border: 1px solid #edf2f7;
    border-radius: 12px;
    padding: 10px 12px;
    transition: all 0.25s ease;
}

.sidebar-store-card:hover {
    transform: translateY(-1.5px);
    box-shadow: 0 6px 15px rgba(0, 71, 171, 0.03);
    border-color: #dbeafe;
}

.sidebar-store-logo {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: #ffffff;
    border: 1px solid #edf2f7;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.sidebar-store-logo img {
    max-width: 80%;
    max-height: 80%;
    object-fit: contain;
}

.sidebar-store-info {
    flex-grow: 1;
}

.sidebar-store-name {
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 2px;
}

.sidebar-store-coupon {
    font-family: var(--font-body);
    font-size: 0.7rem;
    font-weight: 600;
    color: #16a34a;
    margin: 0 0 3px;
}

.sidebar-store-link {
    font-family: var(--font-heading);
    font-size: 0.7rem;
    font-weight: 700;
    color: #0047ab;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.sidebar-store-link:hover {
    color: #3b82f6;
}

/* ─── STICKY TABLE OF CONTENTS (TOC) ─── */
.sticky-toc-wrapper {
    position: sticky;
    top: 24px;
    background: transparent;
    padding: 10px 10px 10px 0;
}

.toc-title {
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
    margin-bottom: 12px;
}

.toc-links {
    display: flex;
    flex-direction: column;
    gap: 6px;
    border-left: 1.5px solid #edf2f7;
}

.toc-link-item {
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 600;
    color: #64748b;
    text-decoration: none;
    padding: 3px 0 3px 14px;
    margin-left: -1.5px;
    border-left: 1.5px solid transparent;
    transition: all 0.2s ease;
    line-height: 1.35;
}

.toc-link-item:hover {
    color: #0047ab;
    border-left-color: #bfdbfe;
}

.toc-link-item.active {
    color: #0047ab;
    border-left-color: #0047ab;
}

/* ─── CITATION WIDGET ─── */
.citation-widget {
    background: #eff6ff;
    border: 1.5px dashed #bfdbfe;
}

.citation-description {
    font-family: var(--font-body);
    font-size: 0.75rem;
    color: #475569;
    line-height: 1.45;
    margin-bottom: 10px;
}

.citation-text {
    font-family: var(--font-body);
    font-size: 0.72rem !important;
    background: #ffffff !important;
    border: 1px solid #bfdbfe !important;
    color: #334155 !important;
    resize: none;
    height: 70px !important;
    padding: 6px !important;
    border-radius: 6px !important;
}

.verify-sidebar-widget {
    border-top: 3px solid #16a34a;
}

.sticky-engagement-wrapper {
    position: sticky;
    top: 24px;
}

/* ── RESPONSIVE ── */
@media (max-width: 767px) {
    .blog-hero { padding: 45px 0 40px; }
    .blog-card-featured { grid-template-columns: 1fr; }
    .blog-card-featured-img { min-height: 200px; }
    .blog-card-featured-body { padding: 24px 20px; }
    .post-hero { padding: 45px 0 40px; }
    .post-cta { padding: 24px 18px; }
    .post-reading-card {
        padding: 24px 18px;
        margin-top: -35px;
        border-radius: 16px;
    }
    .post-author-box {
        flex-direction: column;
        text-align: center;
        gap: 12px;
        padding: 18px;
    }
}
