/* =====================================================
   BLOG.CSS – CLEAN PRODUCTION VERSION
   TellusCreative / Starktillsammans
   ===================================================== */

html,
body,
.wp-site-blocks {
    background-color: #06070d !important;
    background-image: radial-gradient(circle at center, #0b1120 0%, #06070d 100%) !important;
    background-attachment: fixed !important;
    overflow-x: hidden !important;
}

/* =====================================================
   FULL BLEED SECTIONS
   ===================================================== */

.tc-blog-main {
    background: #06070d !important;
    padding: 70px 0 90px !important;
}

.tc-footer {
    background: #040509 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* =====================================================
   CENTERED CONTENT FRAME
   ===================================================== */

.tc-featured-post-section,
.tc-posts-header,
.blogg-grid,
.tc-footer-inner {
    max-width: 1200px !important;
    width: calc(100% - 64px) !important;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box !important;
}

/* =====================================================
   HERO – SOFT GRADIENT FADE IMAGE
   ===================================================== */

.tc-blog-hero {
    position: relative !important;
    min-height: 560px !important;
    padding: 160px 20px 120px !important;
    background: #06070d !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden !important;
}

.tc-blog-hero::before {
    content: "" !important;
    position: absolute !important;
    inset: 0 !important;
    background:
        linear-gradient(
            180deg,
            rgba(6, 7, 13, 0.92) 0%,
            rgba(6, 7, 13, 0.35) 35%,
            rgba(6, 7, 13, 0.55) 68%,
            #06070d 100%
        ),
        radial-gradient(
            ellipse at center,
            rgba(6, 7, 13, 0.02) 0%,
            rgba(6, 7, 13, 0.35) 52%,
            #06070d 100%
        ),
        url("https://images.unsplash.com/photo-1534438327276-14e5300c3a48?q=80&w=2070") center/cover no-repeat !important;
    z-index: 0 !important;
}

.tc-blog-hero-inner {
    position: relative !important;
    z-index: 2 !important;
    max-width: 800px !important;
    text-align: center !important;
}

.tc-blog-title {
    font-family: 'Syne', sans-serif !important;
    font-weight: 800 !important;
    font-size: clamp(2.5rem, 6vw, 4.5rem) !important;
    line-height: 1 !important;
    color: #fff !important;
    text-shadow: 0 10px 30px rgba(0,0,0,0.5) !important;
}

.tc-title-accent {
    color: #22c55e !important;
}

.tc-blog-lead {
    color: rgba(255,255,255,0.9) !important;
    font-size: 1.15rem !important;
    line-height: 1.6 !important;
    max-width: 650px !important;
    margin: 20px auto 0 !important;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5) !important;
}

.tc-blog-cats {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 10px !important;
    margin-top: 24px !important;
}

.tc-hero-cats-label {
    background: rgba(0,0,0,0.3) !important;
    display: inline-block !important;
    padding: 4px 12px !important;
    border-radius: 4px !important;
    backdrop-filter: blur(4px) !important;
    margin-bottom: 15px !important;
}

/* =====================================================
   FEATURED POST
   ===================================================== */

.tc-featured-post-card {
    display: grid !important;
    grid-template-columns: 1.2fr 1fr !important;
    background: rgba(30, 41, 59, 0.4) !important;
    backdrop-filter: blur(15px) !important;
    border-radius: 24px !important;
    border: 1px solid rgba(255,255,255,0.08) !important;
    overflow: hidden !important;
    margin-bottom: 80px !important;
    box-sizing: border-box !important;
}

.tc-featured-post-card .wp-block-post-featured-image,
.tc-featured-post-image {
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    overflow: hidden !important;
}

.tc-featured-post-card .wp-block-post-featured-image a,
.tc-featured-post-card .wp-block-post-featured-image img,
.tc-featured-post-image img {
    width: 100% !important;
    height: 100% !important;
    min-height: 420px !important;
    object-fit: cover !important;
    object-position: center center !important;
    display: block !important;
}

.tc-featured-post-content {
    padding: 60px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    box-sizing: border-box !important;
}

.tc-badge-gold {
    font-size: 0.65rem !important;
    font-weight: 800 !important;
    color: #ffd700 !important;
    background: rgba(255, 215, 0, 0.1) !important;
    padding: 4px 10px !important;
    border-radius: 6px !important;
    border: 1px solid rgba(255, 215, 0, 0.2) !important;
    width: fit-content !important;
}

/* =====================================================
   POSTS GRID
   ===================================================== */

.tc-posts-header {
    margin-bottom: 28px !important;
}

.tc-posts-header h2 {
    font-family: 'Syne', sans-serif !important;
    color: #f1f5f9 !important;
}

.blogg-grid ul.wp-block-post-template,
.blogg-grid .wp-block-post-template {
    width: 100% !important;
    max-width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 30px !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
    box-sizing: border-box !important;
    align-items: stretch !important;
}

.blogg-grid li.wp-block-post,
.blogg-card,
.tc-post-card {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

.blogg-card {
    background: rgba(30, 41, 59, 0.4) !important;
    backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(255,255,255,0.06) !important;
    border-radius: 20px !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    transition: transform 0.3s ease, border-color 0.3s ease !important;
}

.blogg-card:hover {
    transform: translateY(-8px) !important;
    border-color: #22c55e !important;
}

.blogg-image-link {
    width: 100% !important;
    height: 220px !important;
    display: block !important;
    overflow: hidden !important;
}

.tc-card-img-tag,
.blogg-image img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    transition: transform 0.5s ease !important;
}

.blogg-card:hover .tc-card-img-tag {
    transform: scale(1.05) !important;
}

.tc-card-body {
    padding: 24px !important;
    flex-grow: 1 !important;
    display: flex !important;
    flex-direction: column !important;
}

.blogg-card-title,
.blogg-card h3 {
    font-family: 'Syne', sans-serif !important;
    font-size: 1.25rem !important;
    margin: 0 0 12px !important;
    line-height: 1.3 !important;
}

.blogg-card-title a,
.blogg-card h3 a,
.wp-block-post-title a {
    color: #f1f5f9 !important;
    text-decoration: none !important;
    transition: color 0.2s ease !important;
}

.blogg-card:hover h3 a,
.blogg-card-title a:hover {
    color: #22c55e !important;
}

.tc-card-badges {
    display: flex !important;
    gap: 8px !important;
    margin-bottom: 15px !important;
}

.tc-card-category-tag {
    font-size: 0.65rem !important;
    font-weight: 800 !important;
    color: #22c55e !important;
    background: rgba(34, 197, 94, 0.1) !important;
    padding: 4px 10px !important;
    border-radius: 6px !important;
    text-decoration: none !important;
}

.tc-card-category-tag:hover {
    background: rgba(34, 197, 94, 0.2) !important;
}

.tc-card-post-meta {
    display: flex !important;
    justify-content: space-between !important;
    font-size: 0.75rem !important;
    color: rgba(255,255,255,0.4) !important;
    margin-top: auto !important;
    padding-top: 15px !important;
    border-top: 1px solid rgba(255,255,255,0.05) !important;
}

/* =====================================================
   PAGINATION
   ===================================================== */

.wp-block-query-pagination {
    margin-top: 56px !important;
    display: flex !important;
    justify-content: center !important;
    gap: 8px !important;
    flex-wrap: wrap !important;
}

.wp-block-query-pagination a,
.wp-block-query-pagination span {
    padding: 8px 16px !important;
    background: rgba(255,255,255,0.05) !important;
    border-radius: 8px !important;
    color: #fff !important;
    text-decoration: none !important;
}

.wp-block-query-pagination .current {
    background: #22c55e !important;
    color: #06070d !important;
}

/* =====================================================
   FILTER
   ===================================================== */

li.wp-block-post[style*="display: none"] {
    display: none !important;
}

/* =====================================================
   TABLET
   ===================================================== */

@media (max-width: 1024px) {
    .blogg-grid ul.wp-block-post-template,
    .blogg-grid .wp-block-post-template {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 24px !important;
    }

    .tc-featured-post-card {
        grid-template-columns: 1fr !important;
    }

    .tc-featured-post-card .wp-block-post-featured-image img,
    .tc-featured-post-image img {
        min-height: 320px !important;
    }

    .tc-featured-post-content {
        padding: 40px !important;
    }
}

/* =====================================================
   MOBILE
   ===================================================== */

@media (max-width: 768px) {
    .tc-blog-hero {
        min-height: 480px !important;
        padding: 130px 20px 90px !important;
    }

    .tc-blog-title {
        font-size: clamp(2.1rem, 11vw, 3rem) !important;
    }

    .tc-blog-lead {
        font-size: 1rem !important;
    }

    .tc-featured-post-section,
    .tc-posts-header,
    .blogg-grid,
    .tc-footer-inner {
        width: calc(100% - 32px) !important;
        max-width: 100% !important;
    }

    .tc-featured-post-card {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        max-width: 100% !important;
        border-radius: 20px !important;
        overflow: hidden !important;
        margin-bottom: 56px !important;
    }

    .tc-featured-post-card .wp-block-post-featured-image,
    .tc-featured-post-image {
        width: 100% !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        display: block !important;
    }

    .tc-featured-post-card .wp-block-post-featured-image a,
    .tc-featured-post-card .wp-block-post-featured-image img,
    .tc-featured-post-image img {
        width: 100% !important;
        height: 240px !important;
        min-height: 240px !important;
        max-height: 240px !important;
        object-fit: cover !important;
        object-position: center center !important;
        display: block !important;
        margin: 0 !important;
    }

    .tc-featured-post-content {
        width: 100% !important;
        padding: 28px 20px !important;
    }

    .tc-featured-post-content h2,
    .tc-featured-post-content .wp-block-post-title {
        font-size: clamp(1.45rem, 7vw, 2rem) !important;
        line-height: 1.15 !important;
        overflow-wrap: anywhere !important;
    }

    .blogg-grid ul.wp-block-post-template,
    .blogg-grid .wp-block-post-template {
        grid-template-columns: 1fr !important;
        gap: 22px !important;
    }

    .blogg-image-link {
        height: 220px !important;
    }

    .tc-footer {
        text-align: center !important;
    }

    .tc-footer-top {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 32px !important;
        text-align: center !important;
        justify-items: center !important;
    }

    .tc-footer-nav-group,
    .tc-footer-nav-group ul,
    .tc-footer-nav-group li {
        text-align: center !important;
        align-items: center !important;
        justify-content: center !important;
    }

    .tc-footer-nav-group ul {
        padding-left: 0 !important;
    }

    .tc-footer-bottom {
        flex-direction: column !important;
        gap: 18px !important;
        text-align: center !important;
        justify-content: center !important;
    }

    .tc-footer-worlds {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
}

/* =====================================================
   SMALL MOBILE
   ===================================================== */

@media (max-width: 420px) {
    .tc-featured-post-section,
    .tc-posts-header,
    .blogg-grid,
    .tc-footer-inner {
        width: calc(100% - 24px) !important;
    }

    .tc-featured-post-card .wp-block-post-featured-image img,
    .tc-featured-post-image img {
        height: 220px !important;
        min-height: 220px !important;
        max-height: 220px !important;
    }

    .blogg-image-link {
        height: 200px !important;
    }
}

/* =====================================================
   FEATURED POST – BALANCED DESKTOP + MOBILE SAFE
   ===================================================== */

.tc-featured-post-section .wp-block-post-template {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
}

.tc-featured-post-section li.wp-block-post {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
}

.tc-featured-post-section .blogg-card {
    display: grid !important;
    grid-template-columns: 1.15fr 1fr !important;
    align-items: stretch !important;
    width: 100% !important;
    max-width: 100% !important;
    min-height: 0 !important;
    background: rgba(30, 41, 59, 0.4) !important;
    backdrop-filter: blur(15px) !important;
    border-radius: 24px !important;
    border: 1px solid rgba(255,255,255,0.08) !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
    margin-bottom: 70px !important;
}

.tc-featured-post-section .blogg-image-link {
    width: 100% !important;
    height: 360px !important;
    min-height: 0 !important;
    display: block !important;
    overflow: hidden !important;
}

.tc-featured-post-section .tc-card-img-tag,
.tc-featured-post-section .blogg-image-link img {
    width: 100% !important;
    height: 360px !important;
    min-height: 0 !important;
    object-fit: cover !important;
    object-position: center center !important;
    display: block !important;
}

.tc-featured-post-section .tc-card-body {
    padding: 42px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
}

.tc-featured-post-section .blogg-card-title {
    font-size: clamp(1.45rem, 2vw, 2rem) !important;
    line-height: 1.15 !important;
}

/* Mobil */
@media (max-width: 768px) {
    .tc-featured-post-section,
    .tc-posts-header,
    .blogg-grid,
    .tc-footer-inner {
        width: calc(100% - 32px) !important;
        max-width: 100% !important;
    }

    .tc-featured-post-section .blogg-card {
        display: flex !important;
        flex-direction: column !important;
        border-radius: 20px !important;
        margin-bottom: 56px !important;
    }

    .tc-featured-post-section .blogg-image-link {
        width: 100% !important;
        height: clamp(220px, 58vw, 300px) !important;
    }

    .tc-featured-post-section .tc-card-img-tag,
    .tc-featured-post-section .blogg-image-link img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        object-position: center center !important;
    }

    .tc-featured-post-section .tc-card-body {
        padding: 28px 20px !important;
    }

    .blogg-grid ul.wp-block-post-template,
    .blogg-grid .wp-block-post-template {
        grid-template-columns: 1fr !important;
        width: 100% !important;
    }

    .blogg-card,
    .blogg-grid li.wp-block-post {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }

    .tc-footer {
        text-align: center !important;
    }

    .tc-footer-top {
        grid-template-columns: 1fr !important;
        justify-items: center !important;
        text-align: center !important;
    }

    .tc-footer-bottom {
        flex-direction: column !important;
        gap: 18px !important;
        text-align: center !important;
    }
}


/* =====================================================
   FINAL FULL WIDTH BACKGROUND + FOOTER FIX
   ===================================================== */

html,
body {
    margin: 0 !important;
    padding: 0 !important;
    background: #06070d !important;
    overflow-x: hidden !important;
}

.wp-site-blocks {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #06070d !important;
}

/* Wrapper runt footer */
footer.wp-block-template-part {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #040509 !important;
}

/* MAIN BACKGROUND */
.tc-blog-main {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 70px 0 90px !important;
    background: #06070d !important;
    box-shadow: 0 0 0 100vmax #06070d !important;
    clip-path: inset(0 -100vmax) !important;
}

/* FOOTER BACKGROUND */
.tc-footer {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    background: #040509 !important;
    box-shadow: 0 0 0 100vmax #040509 !important;
    clip-path: inset(0 -100vmax) !important;
}

/* =====================================================
   OVERRIDE WP GLOBAL BODY PADDING
   ===================================================== */

body.home.blog {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Behåll snygg innerbredd endast på content */
.tc-nav-inner,
.tc-blog-hero-inner,
.tc-featured-post-section,
.tc-posts-header,
.blogg-grid,
.tc-footer-inner {
    max-width: 1200px !important;
    width: calc(100% - 64px) !important;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box !important;
}

@media (max-width: 768px) {
    .tc-nav-inner,
    .tc-blog-hero-inner,
    .tc-featured-post-section,
    .tc-posts-header,
    .blogg-grid,
    .tc-footer-inner {
        width: calc(100% - 32px) !important;
    }
}

.blogg-grid .blogg-card-title {
    min-height: 88px !important;
}

.blogg-grid .blogg-card-excerpt {
    min-height: 90px !important;
}

.blogg-grid .tc-card-post-meta {
    margin-top: auto !important;
}

/* FIXA OJÄMN HÖJD PÅ FÖRSTA RADEN I GRIDET */
.blogg-grid ul.wp-block-post-template {
    align-items: stretch !important;
    gap: 32px !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Nollställ alla marginaler som WP lägger på första inlägget */
.blogg-grid ul.wp-block-post-template li:first-child,
.blogg-grid ul.wp-block-post-template li {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
}

/* Säkerställ att article-elementet inuti fyller hela höjden */
.blogg-grid li article.blogg-card {
    margin-top: 0 !important;
}

/* Centrera "Fler artiklar" rubriken och ge den jämn luft */
.tc-posts-header {
    margin-top: 60px !important;
    margin-bottom: 30px !important;
    text-align: left;
}

/* =====================================================
   SINGLE ARTICLE PREMIUM STYLING
   ===================================================== */

/* Sidebar stilar */
.tc-article-sidebar {
    position: sticky;
    top: 100px;
}

/* Brödtext */
.tc-article-body, .entry-content {
    color: rgba(255, 255, 255, 0.85) !important;
    font-size: 1.15rem !important;
    line-height: 1.8;
}

.tc-article-body h2, .tc-article-body h3 {
    font-family: 'Syne', sans-serif;
    color: #fff !important;
    margin: 50px 0 20px;
    font-weight: 800;
}

/* Metadata Row */
.tc-article-meta-row {
    display: flex;
    align-items: center;
    gap: 20px;
    color: rgba(255,255,255,0.4);
    font-size: 0.85rem;
    margin-bottom: 30px;
}

/* Dela-box */
.tc-share-box {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    padding: 20px;
    border-radius: 16px;
    margin-top: 20px;
}
.tc-share-title { font-weight: 800; color: #fff; margin-bottom: 15px; font-size: 0.8rem; text-transform: uppercase; }
.tc-share-btns { display: flex; flex-direction: column; gap: 10px; }
.tc-share-btn {
    background: rgba(255,255,255,0.05);
    color: #fff;
    padding: 10px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.85rem;
    text-align: center;
    border: 1px solid transparent;
    transition: all 0.3s;
}
.tc-share-btn:hover { border-color: #22c55e; background: rgba(34,197,94,0.1); }

/* Author Bio */
.tc-author-bio {
    background: rgba(30, 41, 59, 0.4);
    border: 1px solid rgba(255,255,255,0.08);
    padding: 30px;
    border-radius: 20px;
    display: flex;
    gap: 25px;
    margin: 60px 0;
    align-items: center;
}
.tc-author-avatar { width: 80px; height: 80px; border-radius: 50%; object-fit: cover; }
.tc-author-name { font-weight: 800; color: #fff; font-size: 1.1rem; margin: 0; }
.tc-author-desc { color: rgba(255,255,255,0.6); font-size: 0.95rem; margin-top: 5px; }

/* Post Navigation */
.tc-post-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 40px;
}
.tc-pnav-item {
    background: rgba(255,255,255,0.03);
    padding: 20px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s;
}
.tc-pnav-item:hover { background: rgba(255,255,255,0.06); transform: translateY(-3px); }
.tc-pnav-label { display: block; font-size: 0.7rem; color: #22c55e; font-weight: 800; text-transform: uppercase; }
.tc-pnav-title { display: block; color: #fff; margin-top: 5px; font-weight: 600; }

/* MOBILANPASSNING */
@media (max-width: 900px) {
    .single-post .tc-article-wrap {
        grid-template-columns: 1fr;
        padding-top: 60px !important;
    }
    .tc-article-sidebar {
        order: 2; /* Sidebar hamnar under texten på mobil */
    }
    .tc-author-bio { flex-direction: column; text-align: center; }
    .tc-post-nav { grid-template-columns: 1fr; }
}

