/*
 * Blog listing + article styles, ported from the TechOwl Shield site
 * (shield_informative → public/css/style.css) so techowl.com's blog looks and
 * behaves exactly like the Shield one.
 *
 * The palette tokens below are the Shield values; techowl.com's own style.css
 * uses a different set of custom-property names, so nothing here overrides it.
 */
:root {
    --color-accent: #00AEFF;
    --color-white: #FFFFFF;
    --color-text: #FFFFFF;
    --color-text-muted: #cccccc;
    --color-text-muted-2: #cccccc;
    --color-border-soft: #ffffff14;
    --color-border-card: #ffffff1f;
    --color-border-blue: rgba(0, 140, 255, 0.32);
    --color-card-bg: #010516;
    --color-card-bg-2: #0a0d1f;
    --color-card-bg-3: #111323;
}

/* ===== blog listing page (Explore Our Blog & Articles) ===== */
.blog-hero {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    padding: 30px 30px;
    margin: 30px 0px;
    background:
        radial-gradient(120% 160% at 0% 0%, rgba(0, 174, 255, 0.45) 0%, rgba(0, 96, 180, 0.18) 34%, rgba(1, 5, 22, 0) 62%),
        linear-gradient(90deg, #062a52 0%, #041634 42%, var(--color-card-bg) 100%);
    /* border: 1px solid var(--color-border-soft); */
}

/* grid overlay, same look as .surface-box::before */
.blog-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .07) 1px, transparent 1px);
    background-size: 22.74px 22.74px;
    -webkit-mask-image: linear-gradient(100deg, #000 0%, rgba(0, 0, 0, .35) 55%, transparent 90%);
    mask-image: linear-gradient(100deg, #000 0%, rgba(0, 0, 0, .35) 55%, #00000059 90%);
    pointer-events: none;
    z-index: 0;
}

/* keep hero content above the grid overlay */
.blog-hero__eyebrow,
.blog-hero__title,
.blog-hero__sub,
.blog-hero .legal-updated {
    position: relative;
    z-index: 1;
}

.blog-hero__eyebrow {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--color-accent);
    margin: 0 0 8px;
}

.blog-hero__title {
    font-size: 32px;
    font-weight: 500;
    color: var(--color-text);
    margin: 0 0 10px;
}

.blog-hero__sub {
    font-size: 16px;
    color: var(--color-text-muted-2);
    margin: 0;
}

/* category filter chips */
.blog-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 32px;
}

.blog-chip {
    background: var(--color-card-bg-2);
    border: 1px solid var(--color-border-card);
    color: var(--color-text-muted-2);
    font-size: 14px;
    font-weight: 500;
    padding: 8px 18px;
    border-radius: 999px;
    cursor: pointer;
    transition: all .2s ease;
}

.blog-chip:hover {
    color: var(--color-text);
    border-color: var(--color-border-blue);
}

.blog-chip.active {
    background: var(--color-accent);
    border-color: var(--color-accent);
    color: #ffffff;
}

/* post card (vertical) */
.post-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #181A2A;
    border: 2px solid #242535;
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
}

.post-card:hover {
    border-color: var(--color-border-blue);
}

.post-card__thumb {
    aspect-ratio: 16 / 9;
    overflow: hidden;
    padding: 20px 20px 0px 20px;
}

.post-card__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 6px;
    transition: transform .4s ease;
}

.post-card:hover .post-card__thumb img {
    transform: scale(1.01);

}

.post-card__body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    padding: 20px;
}

.post-card__cat {
    display: inline-block;
    color: var(--color-accent);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 12px;
    background-color: #4b6bfb0d;
    width:fit-content;
    padding: 4px 10px;
    border-radius: 8px;
}

.post-card__title {
    font-size: 18px;
    font-weight: 500;
    line-height: 1.4;
    color: var(--color-text);
    margin: 0 0 20px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color .2s ease;
}

.post-card:hover .post-card__title {
    color: var(--color-accent);
}

.post-card__meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: auto;
}

.post-card__avatar {
    width: 28px;
    /* height: 30px; */
    /* border-radius: 50%; */
    object-fit: cover;
    flex: 0 0 auto;
}

.post-card__author {
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-muted-2);
}

.post-card__date {
    font-size: 14px;
     font-weight: 500;
    color: var(--color-text-muted-2);
}

.post-card__date::before {
    content: "";
    display: inline-block;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--color-text-muted);
    vertical-align: middle;
    margin-right: 8px;
}

/* pagination */
.blog-pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    list-style: none;
    padding: 0;
    margin: 40px 0 0;
    flex-wrap: wrap;
}

.blog-pagination .page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 10px;
    border-radius: 8px !important;
    background: transparent;
    border: 1px solid transparent;
    color: var(--color-text);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s ease;
}

.blog-pagination .page-link:hover {
    border-color: var(--color-border-blue);
}

.blog-pagination .page-item.active .page-link {
    background: var(--color-accent);
    color: #ffffff;
    border-radius: 8px;
}

.blog-pagination .page-item.disabled .page-link {
    color: var(--color-text-muted);
    cursor: default;
}

.blog-spinner {
    display: none;
    text-align: center;
    padding: 40px 0;
    color: var(--color-accent);
}

/* ===== blog detail / article page ===== */
.article-breadcrumb {
    font-size: 14px;
    color: var(--color-text-muted);
    margin-bottom: 26px;
}

.article-breadcrumb a {
    color: var(--color-text-muted-2);
    text-decoration: none;
    transition: color .2s ease;
}

.article-breadcrumb a:hover {
    color: var(--color-accent);
}

.article-head {
    margin-bottom: 20px;
}

.article-cat {
    display: inline-block;
    color: var(--color-accent);
    font-size: 16px;
    font-weight: 500;
    margin: 14px 0px;
}

.article-title {
    font-size: 32px;
    font-weight: 500;
    line-height: 1.25;
    color: var(--color-text);
    margin: 0 0 20px;
    border-bottom:none;
}

.article-meta {
    display: flex;
    align-items: center;
    gap: 10px;
}

.article-meta__avatar {
    width: 30px;
    /* height: 34px;
    border-radius: 50%; */
    object-fit: cover;
}

.article-meta__author {
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-muted-2);
}

.article-meta__date {
    font-size: 14px;
    color: var(--color-text-muted-2);
    font-weight: 500;
}

.article-meta__date::before {
    content: "";
    display: inline-block;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--color-text-muted);
    vertical-align: middle;
    margin-right: 8px;
}

.article-hero {
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 36px;
    border: 1px solid var(--color-border-soft);
}

.article-hero img {
    width: 100%;
    height: auto;
    display: block;
}

/* rich text body */
.article-content {
    color: var(--color-text-muted-2);
    font-size: 1.02rem;
    line-height: 1.85;
    word-break: break-word;
}

.article-content > *:first-child {
    margin-top: 0;
}

.article-content p {
    margin: 0 0 1.15em;
}

.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6 {
    /* color: var(--color-text); */
    font-weight: 600;
    line-height: 1.3;
    margin: 1.7em 0 .6em;
}

.article-content h1 { font-size: 1.9rem; }
.article-content h2 { font-size: 1.55rem; }
.article-content h3 { font-size: 1.3rem; }
.article-content h4 { font-size: 1.12rem; }

.article-content a {
    color: var(--color-accent);
    text-decoration: none;
}

.article-content a:hover {
    text-decoration: underline;
}

.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 1.4em 0;
}

/* CMS articles wrap their inline SVG diagrams in <figure class="figure">, which
   collides with Bootstrap's `.figure { display: inline-block }`. That shrink-wraps
   the figure, so a child sized with width:100% falls back to the SVG's default
   300px intrinsic width instead of filling the column. Force block layout back. */
.article-content figure,
.article-content .figure {
    display: block;
    width: 100%;
    max-width: 100%;
}

.article-content figure svg,
.article-content .figure svg {
    display: block;
    width: 100%;
    height: auto;
}

.article-content ul,
.article-content ol {
    padding-left: 1.4em;
    margin: 0 0 1.15em;
}

.article-content li {
    margin-bottom: .5em;
}

.article-content blockquote {
    border-left: 3px solid var(--color-accent);
    padding: 4px 0 4px 18px;
    margin: 1.4em 0;
    color: var(--color-text-muted);
    font-style: italic;
}

.article-content pre {
    background: var(--color-card-bg-3);
    border: 1px solid var(--color-border-card);
    border-radius: 10px;
    padding: 16px;
    overflow: auto;
    font-size: .85rem;
    margin: 1.4em 0;
}

.article-content code {
    background: var(--color-card-bg-3);
    border-radius: 4px;
    padding: 2px 6px;
    font-size: .88em;
}

.article-content pre code {
    background: transparent;
    padding: 0;
}

.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.4em 0;
    font-size: .95rem;
    display: block;
    overflow-x: auto;
}

.article-content th,
.article-content td {
    border: 1px solid var(--color-border-card);
    padding: 10px 12px;
    text-align: left;
}

.article-content th {
    background: var(--color-card-bg-3);
    color: var(--color-text);
}

.article-content hr {
    border: 0;
    border-top: 1px solid var(--color-border-card);
    margin: 2em 0;
}

/* related posts sidebar */
.related-panel {
    position: sticky;
    top: 90px;
}

.related-panel__title {
    font-size: 18px;
    font-weight: 500;
    color: var(--color-accent) !important;
    margin: 0px;
    padding-bottom: 14px;
}

.related-post {
    display: flex;
    gap: 14px;
    margin-bottom: 20px;
    text-decoration: none;
}

.related-post__img {
    flex: 0 0 140px;
    width: 85px;
    height: 85px;
    border-radius: 8px;
    overflow: hidden;
    background: var(--color-card-bg-3);
}

.related-post__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease;
}

.related-post:hover .related-post__img img {
    transform: scale(1.06);
}

.related-post__text {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.related-post__title {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    color: var(--color-white);
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color .2s ease;
}

.related-post:hover .related-post__title {
    color: var(--color-accent);
}

.related-post__more {
    font-size: 13px;
    font-weight: 600;
    color: var(--color-accent);
    transition: opacity .2s ease;
}

.related-post:hover .related-post__more {
    opacity: .8;
}

