/* Blog post detail page */

.blog-detail {
    background:
        radial-gradient(ellipse 80% 50% at 10% -10%, rgba(68, 50, 151, 0.09), transparent 55%),
        linear-gradient(180deg, #f7f6fb 0%, #f3f4f6 180px, #f9fafb 100%);
    padding: 1.5rem 0 3.5rem;
}

@media (min-width: 768px) {
    .blog-detail {
        padding: 2rem 0 4rem;
    }
}

.blog-detail__breadcrumb {
    margin-bottom: 1.25rem;
}

.blog-detail__breadcrumb-list {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.blog-detail__breadcrumb-item {
    align-items: center;
    color: #667085;
    display: inline-flex;
    font-size: 0.82rem;
    font-weight: 500;
    gap: 0.5rem;
}

.blog-detail__breadcrumb-item a {
    color: #667085;
    text-decoration: none;
    transition: color 0.15s ease;
}

.blog-detail__breadcrumb-item a:hover {
    color: #443297;
}

.blog-detail__breadcrumb-item.is-active {
    color: #101828;
    font-weight: 600;
}

.blog-detail__breadcrumb-sep {
    color: #d0d5dd;
    font-size: 0.65rem;
}

.blog-detail__hero {
    border-radius: 22px;
    margin: 0 auto 1.75rem;
    max-width: 56rem;
    overflow: hidden;
    position: relative;
}

.blog-detail__hero::after {
    background: linear-gradient(180deg, transparent 55%, rgba(16, 24, 40, 0.35) 100%);
    content: "";
    inset: 0;
    pointer-events: none;
    position: absolute;
}

.blog-detail__hero-image {
    aspect-ratio: 21 / 9;
    display: block;
    height: auto;
    object-fit: cover;
    width: 100%;
}

@media (max-width: 767px) {
    .blog-detail__hero-image {
        aspect-ratio: 16 / 10;
    }
}

.blog-detail__hero-placeholder {
    align-items: center;
    aspect-ratio: 21 / 9;
    background: linear-gradient(135deg, rgba(68, 50, 151, 0.12), rgba(68, 50, 151, 0.04));
    color: #443297;
    display: flex;
    font-size: 2.5rem;
    justify-content: center;
}

.blog-detail__article {
    background: #fff;
    border: 1px solid rgba(68, 50, 151, 0.1);
    border-radius: 24px;
    box-shadow: 0 16px 40px rgba(68, 50, 151, 0.06);
    margin: 0 auto 2rem;
    max-width: 46rem;
    padding: 1.75rem 1.35rem 1.5rem;
}

@media (min-width: 768px) {
    .blog-detail__article {
        padding: 2.25rem 2.5rem 2rem;
    }
}

.blog-detail__header {
    margin-bottom: 1.75rem;
    text-align: center;
}

.blog-detail__category {
    background: rgba(68, 50, 151, 0.08);
    border-radius: 999px;
    color: #443297;
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    margin-bottom: 0.85rem;
    padding: 0.35rem 0.85rem;
    text-decoration: none;
    text-transform: uppercase;
    transition: background-color 0.15s ease, color 0.15s ease;
}

a.blog-detail__category:hover {
    background: #443297;
    color: #fff;
}

.blog-detail__title {
    color: #101828;
    font-size: clamp(1.65rem, 3.5vw, 2.25rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.2;
    margin: 0 0 0.85rem;
}

.blog-detail__meta {
    align-items: center;
    color: #667085;
    display: flex;
    flex-wrap: wrap;
    font-size: 0.88rem;
    gap: 0.5rem 1rem;
    justify-content: center;
}

.blog-detail__meta-item {
    align-items: center;
    display: inline-flex;
    gap: 0.4rem;
}

.blog-detail__meta-item i {
    color: #443297;
    font-size: 0.82rem;
    opacity: 0.85;
}

.blog-detail__content {
    color: #344054;
    font-size: 1.02rem;
    line-height: 1.75;
}

.blog-detail__content > *:first-child {
    margin-top: 0;
}

.blog-detail__content > *:last-child {
    margin-bottom: 0;
}

.blog-detail__content h2,
.blog-detail__content h3,
.blog-detail__content h4 {
    color: #101828;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.3;
    margin: 1.75rem 0 0.75rem;
}

.blog-detail__content h2 {
    font-size: 1.45rem;
}

.blog-detail__content h3 {
    font-size: 1.2rem;
}

.blog-detail__content h4 {
    font-size: 1.05rem;
}

.blog-detail__content p {
    margin: 0 0 1.1rem;
}

.blog-detail__content ul,
.blog-detail__content ol {
    margin: 0 0 1.1rem;
    padding-left: 1.35rem;
}

.blog-detail__content li {
    margin-bottom: 0.4rem;
}

.blog-detail__content li::marker {
    color: #443297;
}

.blog-detail__content a {
    color: #443297;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: rgba(68, 50, 151, 0.35);
    text-underline-offset: 0.15em;
}

.blog-detail__content a:hover {
    text-decoration-color: #443297;
}

.blog-detail__content img {
    border-radius: 14px;
    height: auto;
    margin: 1.25rem 0;
    max-width: 100%;
}

.blog-detail__content blockquote {
    background: rgba(68, 50, 151, 0.05);
    border-left: 4px solid #443297;
    border-radius: 0 12px 12px 0;
    color: #475467;
    font-style: italic;
    margin: 1.5rem 0;
    padding: 1rem 1.15rem;
}

.blog-detail__content pre,
.blog-detail__content code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.9em;
}

.blog-detail__content pre {
    background: #101828;
    border-radius: 12px;
    color: #f2f4f7;
    overflow-x: auto;
    padding: 1rem 1.15rem;
}

.blog-detail__content table {
    border-collapse: collapse;
    display: block;
    margin: 1.25rem 0;
    overflow-x: auto;
    width: 100%;
}

.blog-detail__content th,
.blog-detail__content td {
    border: 1px solid #eaecf0;
    padding: 0.55rem 0.75rem;
    text-align: left;
}

.blog-detail__content th {
    background: #f9fafb;
    color: #101828;
    font-weight: 700;
}

.blog-detail__footer {
    border-top: 1px solid #eaecf0;
    display: flex;
    flex-direction: column;
    gap: 1.15rem;
    margin-top: 2rem;
    padding-top: 1.5rem;
}

@media (min-width: 768px) {
    .blog-detail__footer {
        align-items: center;
        flex-direction: row;
        justify-content: space-between;
    }
}

.blog-detail__share-label {
    color: #667085;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    margin: 0 0 0.55rem;
    text-transform: uppercase;
}

.blog-detail__share-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.blog-detail__share-link {
    align-items: center;
    background: #f9fafb;
    border: 1px solid #eaecf0;
    border-radius: 999px;
    color: #475467;
    display: inline-flex;
    font-size: 0.95rem;
    height: 2.35rem;
    justify-content: center;
    text-decoration: none;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
    width: 2.35rem;
}

.blog-detail__share-link:hover {
    background: #443297;
    border-color: #443297;
    color: #fff;
    transform: translateY(-1px);
}

.blog-detail__share-link--telegram:hover {
    background: #229ed9;
    border-color: #229ed9;
}

.blog-detail__share-link--whatsapp:hover {
    background: #25d366;
    border-color: #25d366;
}

.blog-detail__share-link--email:hover {
    background: #475467;
    border-color: #475467;
}

.blog-detail__tags {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

@media (min-width: 768px) {
    .blog-detail__tags {
        align-items: flex-end;
    }
}

.blog-detail__tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: flex-start;
    list-style: none;
    margin: 0;
    padding: 0;
}

@media (min-width: 768px) {
    .blog-detail__tags-list {
        justify-content: flex-end;
    }
}

.blog-detail__tag {
    background: rgba(68, 50, 151, 0.06);
    border: 1px solid rgba(68, 50, 151, 0.12);
    border-radius: 999px;
    color: #443297;
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.35rem 0.75rem;
    text-decoration: none;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.blog-detail__tag:hover {
    background: #443297;
    border-color: #443297;
    color: #fff;
}

.blog-detail__adjacent {
    display: grid;
    gap: 0.85rem;
    grid-template-columns: 1fr;
    margin: 0 auto 2.5rem;
    max-width: 46rem;
}

@media (min-width: 768px) {
    .blog-detail__adjacent {
        grid-template-columns: 1fr 1fr;
    }
}

.blog-detail__adjacent-link {
    align-items: stretch;
    background: #fff;
    border: 1px solid rgba(68, 50, 151, 0.1);
    border-radius: 18px;
    color: inherit;
    display: flex;
    gap: 0.85rem;
    padding: 1rem 1.1rem;
    text-decoration: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.blog-detail__adjacent-link:hover {
    border-color: rgba(68, 50, 151, 0.22);
    box-shadow: 0 10px 24px rgba(68, 50, 151, 0.08);
    transform: translateY(-2px);
}

.blog-detail__adjacent-link--next {
    grid-column: 1;
}

@media (min-width: 768px) {
    .blog-detail__adjacent-link--next {
        grid-column: 2;
        justify-self: end;
        text-align: right;
    }

    .blog-detail__adjacent-link--next .blog-detail__adjacent-body {
        align-items: flex-end;
    }
}

.blog-detail__adjacent-link--placeholder {
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
}

.blog-detail__adjacent-icon {
    align-items: center;
    background: rgba(68, 50, 151, 0.08);
    border-radius: 999px;
    color: #443297;
    display: inline-flex;
    flex-shrink: 0;
    font-size: 0.85rem;
    height: 2.25rem;
    justify-content: center;
    width: 2.25rem;
}

.blog-detail__adjacent-body {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 0;
}

.blog-detail__adjacent-label {
    color: #443297;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    margin: 0;
    text-transform: uppercase;
}

.blog-detail__adjacent-title {
    color: #101828;
    display: -webkit-box;
    font-size: 0.92rem;
    font-weight: 700;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-height: 1.4;
    margin: 0;
    overflow: hidden;
}

.blog-detail__related {
    margin: 0 auto;
    max-width: 56rem;
}

.blog-detail__related-header {
    align-items: flex-end;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.blog-detail__related-title {
    color: #101828;
    font-size: clamp(1.25rem, 2vw, 1.55rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0;
}

.blog-detail__related-link {
    align-items: center;
    color: #443297;
    display: inline-flex;
    font-size: 0.84rem;
    font-weight: 700;
    gap: 0.4rem;
    text-decoration: none;
}

.blog-detail__related-link:hover {
    text-decoration: underline;
}

.blog-detail__related-grid {
    display: grid;
    gap: 1.15rem;
    grid-template-columns: 1fr;
}

@media (min-width: 576px) {
    .blog-detail__related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 992px) {
    .blog-detail__related-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.blog-detail__related-empty {
    background: #fff;
    border: 1px dashed #d0d5dd;
    border-radius: 18px;
    color: #667085;
    font-size: 0.92rem;
    margin: 0;
    padding: 2rem 1.25rem;
    text-align: center;
}

.blog-detail__back {
    margin: 2rem auto 0;
    max-width: 46rem;
    text-align: center;
}

.blog-detail__back-link {
    align-items: center;
    background: rgba(68, 50, 151, 0.08);
    border: 1px solid rgba(68, 50, 151, 0.12);
    border-radius: 999px;
    color: #443297;
    display: inline-flex;
    font-size: 0.88rem;
    font-weight: 700;
    gap: 0.45rem;
    padding: 0.65rem 1.1rem;
    text-decoration: none;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.blog-detail__back-link:hover {
    background: #443297;
    border-color: #443297;
    color: #fff;
    transform: translateY(-1px);
}
