/*
 * Blog: index, archives and post pages (templates archive.php, single.php,
 * partials/blog-*.php). Colours follow the rest of the theme: primary
 * #6366f1, purple accents, and the footer CTA's navy for the closing card.
 * Post bodies are set in the site's Inter with a generous reading line
 * height.
 */

.vsb {
    --vsb-primary: #6366f1;
    --vsb-primary-dark: #4f46e5;
    --vsb-ink: #111827;
    --vsb-text: #242424;
    --vsb-muted: #6b7280;
    --vsb-line: #e5e7eb;
    --vsb-soft: #f3f4f6;
    color: var(--vsb-ink);
}

/* ---------- Shared bits ---------- */

.vsb-eyebrow {
    display: inline-flex;
    margin: 0 0 1rem;
    padding: .375rem 1rem;
    border-radius: 999px;
    background: rgba(99, 102, 241, .1);
    color: var(--vsb-primary);
    font-size: .8125rem;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.vsb-breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem;
    margin-bottom: 1.25rem;
    color: var(--vsb-muted);
    font-size: .875rem;
}
.vsb-breadcrumbs a { color: inherit; text-decoration: none; }
.vsb-breadcrumbs a:hover { color: var(--vsb-primary); }
.vsb-breadcrumbs span { color: #d1d5db; }

.vsb-pill {
    display: inline-block;
    margin-bottom: .75rem;
    padding: .25rem .75rem;
    border-radius: 999px;
    background: #eef2ff;
    color: var(--vsb-primary-dark);
    font-size: .75rem;
    font-weight: 600;
    text-decoration: none;
    transition: background .2s;
}
.vsb-pill:hover { background: #e0e7ff; }

.vsb-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    min-height: 44px;
    padding: .625rem 1.25rem;
    border-radius: .75rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform .2s, box-shadow .2s, background .2s;
}
.vsb-btn:hover { transform: translateY(-1px); }
.vsb-btn--primary { background: var(--vsb-primary); color: #fff; }
.vsb-btn--primary:hover { background: var(--vsb-primary-dark); box-shadow: 0 10px 24px -8px rgba(99, 102, 241, .6); }
.vsb-btn--light { background: #fff; color: #312e81; }
.vsb-btn--light:hover { box-shadow: 0 12px 28px -10px rgba(0, 0, 0, .5); }
.vsb-btn--ghost { border: 1px solid rgba(255, 255, 255, .35); color: #fff; }
.vsb-btn--ghost:hover { background: rgba(255, 255, 255, .08); }

/* Medium-style topic chips */
.vsb-tags { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0; padding: 0; list-style: none; }
.vsb-tag {
    display: inline-block;
    padding: .5rem 1rem;
    border-radius: 999px;
    background: var(--vsb-soft);
    color: var(--vsb-text);
    font-size: .875rem;
    line-height: 1.25;
    text-decoration: none;
    transition: background .2s, color .2s;
}
.vsb-tag:hover { background: #e5e7eb; }
.vsb-tag[aria-current] { background: var(--vsb-primary); color: #fff; }

.vsb-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .375rem;
    color: var(--vsb-muted);
    font-size: .8125rem;
}

/* ---------- Layout ---------- */

.vsb-hero {
    padding: 7.5rem 1rem 3.5rem;
    background: linear-gradient(135deg, #faf5ff 0%, #eff6ff 100%);
    text-align: center;
}
.vsb-hero__inner { max-width: 48rem; margin: 0 auto; }
.vsb-hero .vsb-breadcrumbs { justify-content: center; }
.vsb-hero__title {
    margin: 0 0 1rem;
    font-size: clamp(2rem, 5vw, 3.25rem);
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -.02em;
}
.vsb-hero__title span { color: var(--vsb-primary); }
.vsb-hero__intro { margin: 0 auto; max-width: 40rem; color: #4b5563; font-size: 1.125rem; line-height: 1.7; }

.vsb-layout {
    display: grid;
    gap: 3rem;
    max-width: 80rem;
    margin: 0 auto;
    padding: 3rem 1rem 5rem;
}
.vsb-main { min-width: 0; }

@media (min-width: 640px) {
    .vsb-layout { padding-right: 1.5rem; padding-left: 1.5rem; }
}

@media (min-width: 1024px) {
    .vsb-layout { grid-template-columns: minmax(0, 1fr) 300px; gap: 3.5rem; padding-right: 2rem; padding-left: 2rem; }
}

/* ---------- Sidebar ---------- */

.vsb-sidebar { display: flex; flex-direction: column; gap: 1.5rem; }
.vsb-sidebar__sticky { display: flex; flex-direction: column; gap: 1.5rem; }

/* Post pages: the contents follow the reader. On smaller
   screens the contents open from the top of the article instead, and the
   sidebar (which would sit below the whole post) is left out. */
@media (min-width: 1024px) {
    .vsb-sidebar__sticky { position: sticky; top: 5.5rem; }
    .vsb-sidebar__sticky .vsb-toc ol { max-height: calc(100vh - 13rem); overflow-y: auto; overscroll-behavior: contain; }
    .vsb-toc--mobile { display: none; }
}
@media (max-width: 1023px) {
    .vsb--single .vsb-sidebar { display: none; }
}
.vsb-toc--mobile { margin: 0 0 2rem; border: 1px solid var(--vsb-line); border-radius: 1rem; background: #fff; }
.vsb-toc--mobile summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    color: var(--vsb-ink);
    font-size: .8125rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    list-style: none;
    cursor: pointer;
}
.vsb-toc--mobile summary::-webkit-details-marker { display: none; }
.vsb-toc--mobile summary::after { content: ""; width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translateY(-2px); transition: transform .2s; }
.vsb-toc--mobile[open] summary::after { transform: rotate(-135deg) translateY(-2px); }
.vsb-toc--mobile ol { margin: 0 1.25rem 1rem; }


.vsb-widget { padding: 1.25rem; border: 1px solid var(--vsb-line); border-radius: 1rem; background: #fff; }
.vsb-widget__title {
    margin: 0 0 1rem;
    color: var(--vsb-ink);
    font-size: .8125rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.vsb-search { position: relative; }
.vsb-search svg { position: absolute; top: 50%; left: .875rem; width: 1.125rem; height: 1.125rem; color: #9ca3af; transform: translateY(-50%); pointer-events: none; }
.vsb-search input[type="search"] {
    width: 100%;
    padding: .75rem 5.25rem .75rem 2.5rem;
    border: 1px solid var(--vsb-line);
    border-radius: 999px;
    background: #fff;
    font-size: .9375rem;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}
.vsb-search input[type="search"]:focus { border-color: var(--vsb-primary); box-shadow: 0 0 0 3px rgba(99, 102, 241, .15); }
.vsb-search input[type="search"]::-webkit-search-cancel-button { display: none; }
.vsb-search__submit {
    position: absolute;
    top: .3125rem;
    right: .3125rem;
    bottom: .3125rem;
    padding: 0 1rem;
    border: 0;
    border-radius: 999px;
    background: var(--vsb-primary);
    color: #fff;
    font-size: .8125rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .2s;
}
.vsb-search__submit:hover, .vsb-search__submit:focus-visible { background: #4f46e5; }

.vsb-recent { display: flex; flex-direction: column; gap: 1rem; margin: 0; padding: 0; list-style: none; }
.vsb-recent__link { display: flex; gap: .75rem; align-items: flex-start; color: inherit; text-decoration: none; }
.vsb-recent__thumb { flex: none; width: 56px; height: 56px; border-radius: .625rem; object-fit: cover; }
.vsb-recent__title {
    display: -webkit-box;
    overflow: hidden;
    color: var(--vsb-ink);
    font-size: .875rem;
    font-weight: 600;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    transition: color .2s;
}
.vsb-recent__link:hover .vsb-recent__title { color: var(--vsb-primary); }
.vsb-recent__date { display: block; margin-top: .25rem; color: var(--vsb-muted); font-size: .75rem; }

.vsb-cats { margin: 0; padding: 0; list-style: none; }
.vsb-cats a { display: flex; justify-content: space-between; padding: .5rem 0; color: #374151; font-size: .9375rem; text-decoration: none; }
.vsb-cats a:hover, .vsb-cats a[aria-current] { color: var(--vsb-primary); }
.vsb-cats span { color: #9ca3af; font-size: .8125rem; }

.vsb-toc ol { margin: 0; padding: 0; list-style: none; border-left: 2px solid var(--vsb-line); }
.vsb-toc a {
    display: block;
    margin-left: -2px;
    padding: .375rem 0 .375rem .875rem;
    border-left: 2px solid transparent;
    color: var(--vsb-muted);
    font-size: .875rem;
    line-height: 1.4;
    text-decoration: none;
    transition: color .2s, border-color .2s;
}
.vsb-toc__item--h3 a { padding-left: 1.625rem; font-size: .8125rem; }
.vsb-toc a:hover { color: var(--vsb-ink); }
.vsb-toc a[aria-current] { border-left-color: var(--vsb-primary); color: var(--vsb-primary); font-weight: 600; }

.vsb-mini__people b {
    display: inline-flex;
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
    border-radius: 50%;
    background: var(--c);
    color: #fff;
    font-size: .75rem;
    font-weight: 700;
}

/* ---------- Cards ---------- */

.vsb-grid { display: grid; gap: 1.75rem; }
@media (min-width: 640px) { .vsb-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .vsb-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.vsb-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #eef0f4;
    border-radius: 1.25rem;
    background: #fff;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
    transition: transform .25s ease, box-shadow .25s ease;
}
.vsb-card:hover { transform: translateY(-4px); box-shadow: 0 20px 40px -18px rgba(79, 70, 229, .35); }
.vsb-card__media { display: block; overflow: hidden; aspect-ratio: 16 / 9; background: #eef2ff; }
.vsb-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.vsb-card:hover .vsb-card__media img { transform: scale(1.04); }
.vsb-card__placeholder { display: block; width: 100%; height: 100%; background: linear-gradient(135deg, #e0e7ff, #f3e8ff); }
.vsb-card__body { display: flex; flex: 1; flex-direction: column; align-items: flex-start; padding: 1.5rem; }
.vsb-card__title { margin: 0 0 .625rem; font-size: 1.25rem; font-weight: 700; line-height: 1.35; letter-spacing: -.01em; }
.vsb-card__title a { color: var(--vsb-ink); text-decoration: none; transition: color .2s; }
.vsb-card__title a:hover { color: var(--vsb-primary); }
.vsb-card__excerpt { flex: 1; margin: 0 0 1.25rem; color: #4b5563; font-size: .9375rem; line-height: 1.65; }

.vsb-card--featured { margin-bottom: 1.75rem; }
.vsb-card--featured .vsb-card__title { font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.2; }
.vsb-card--featured .vsb-card__excerpt { font-size: 1.0625rem; }
@media (min-width: 768px) {
    .vsb-card--featured { display: grid; grid-template-columns: 1.1fr 1fr; }
    .vsb-card--featured .vsb-card__media { aspect-ratio: auto; min-height: 340px; }
    .vsb-card--featured .vsb-card__body { justify-content: center; padding: 2.5rem; }
}

.vsb-pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin-top: 3rem; }
.vsb-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 1rem;
    border: 1px solid var(--vsb-line);
    border-radius: .75rem;
    background: #fff;
    color: #374151;
    font-weight: 500;
    text-decoration: none;
}
.vsb-pagination a.page-numbers:hover { border-color: var(--vsb-primary); color: var(--vsb-primary); }
.vsb-pagination .current { border-color: var(--vsb-primary); background: var(--vsb-primary); color: #fff; }
.vsb-pagination .dots { border: 0; background: none; }

.vsb-empty { padding: 4rem 1.5rem; border: 1px dashed #d1d5db; border-radius: 1.25rem; background: #fff; text-align: center; }
.vsb-empty h2 { margin: 0 0 .5rem; font-size: 1.5rem; font-weight: 700; }
.vsb-empty p { margin: 0 0 1.5rem; color: var(--vsb-muted); }

/* ---------- Post page ---------- */

.vsb--single { background: #fff; }
.vsb--single .vsb-layout { padding-top: 6.5rem; }
.vsb-article { width: 100%; max-width: 46rem; }
@media (min-width: 1280px) { .vsb-article { margin-left: 1.5rem; } }

.vsb-article__title {
    margin: 0 0 1rem;
    color: var(--vsb-ink);
    font-size: clamp(2rem, 4.6vw, 2.875rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -.022em;
}
.vsb-article__dek { margin: 0 0 1.75rem; color: var(--vsb-muted); font-family: Inter, sans-serif; font-size: 1.1875rem; line-height: 1.6; }

.vsb-byline { display: flex; align-items: center; gap: .875rem; padding: 1rem 0; border-top: 1px solid var(--vsb-soft); border-bottom: 1px solid var(--vsb-soft); }
.vsb-byline__meta { display: flex; flex-wrap: wrap; gap: .375rem; color: var(--vsb-muted); font-size: .875rem; }

.vsb-article__hero { margin: 2rem 0 2.5rem; }
.vsb-article__hero img { width: 100%; height: auto; max-height: 520px; border-radius: 1rem; object-fit: cover; }

/* Reading column */
.vsb-prose { color: var(--vsb-text); font-family: Inter, sans-serif; font-size: 1.0625rem; line-height: 1.8; overflow-wrap: break-word; }
@media (min-width: 768px) { .vsb-prose { font-size: 1.125rem; line-height: 1.85; } }
.vsb-prose > * { margin-top: 0; margin-bottom: 1.6em; }
.vsb-prose h2, .vsb-prose h3, .vsb-prose h4 {
    margin: 1.9em 0 .6em;
    color: var(--vsb-ink);
    font-family: Inter, sans-serif;
    font-weight: 700;
    letter-spacing: -.015em;
    scroll-margin-top: 90px;
}
.vsb-prose h2 { font-size: 1.625rem; line-height: 1.3; }
.vsb-prose h3 { font-size: 1.3125rem; line-height: 1.35; }
.vsb-prose h4 { font-size: 1.125rem; }
.vsb-prose a { color: inherit; text-decoration: underline; text-decoration-color: rgba(99, 102, 241, .5); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.vsb-prose a:hover { color: var(--vsb-primary); text-decoration-color: var(--vsb-primary); }
.vsb-prose strong { color: var(--vsb-ink); font-weight: 700; }
.vsb-prose ul, .vsb-prose ol { padding-left: 1.5em; }
.vsb-prose ul { list-style: disc; }
.vsb-prose ol { list-style: decimal; }
.vsb-prose ol:empty, .vsb-prose ul:empty, .vsb-prose p:empty { display: none; }
.vsb-prose li { margin-bottom: .5em; padding-left: .25em; }
.vsb-prose li::marker { color: var(--vsb-primary); }
.vsb-prose blockquote, .vsb-prose .wp-block-quote {
    margin-left: 0;
    padding: .25em 0 .25em 1.25em;
    border-left: 3px solid var(--vsb-primary);
    color: #374151;
    font-style: italic;
}
.vsb-prose .wp-block-pullquote { border-top: 3px solid var(--vsb-primary); border-bottom: 3px solid var(--vsb-primary); text-align: center; }
.vsb-prose img { max-width: 100%; height: auto; border-radius: .75rem; }
.vsb-prose figure { margin-right: 0; margin-left: 0; }
.vsb-prose figcaption { margin-top: .625rem; color: var(--vsb-muted); font-family: Inter, sans-serif; font-size: .875rem; text-align: center; }
.vsb-prose hr, .vsb-prose .wp-block-separator { width: 100%; margin: 2.5em auto; border: 0; border-top: 1px solid var(--vsb-line); }
.vsb-prose code { padding: .15em .4em; border-radius: .375rem; background: var(--vsb-soft); font-size: .85em; }
.vsb-prose pre { overflow-x: auto; padding: 1.25rem; border-radius: .75rem; background: #111827; color: #e5e7eb; font-size: .875rem; line-height: 1.6; }
.vsb-prose pre code { padding: 0; background: none; }
.vsb-prose table { width: 100%; border-collapse: collapse; font-family: Inter, sans-serif; font-size: .9375rem; }
.vsb-prose th, .vsb-prose td { padding: .625rem .75rem; border-bottom: 1px solid var(--vsb-line); text-align: left; }
.vsb-prose mark { background: none; color: inherit; }
.vsb-prose iframe, .vsb-prose video { max-width: 100%; }

.vsb-article__footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.25rem; margin-top: 2.5rem; padding-bottom: 2rem; border-bottom: 1px solid var(--vsb-soft); }

.vsb-share { display: flex; align-items: center; gap: .5rem; }
.vsb-share__label { margin-right: .25rem; color: var(--vsb-muted); font-size: .875rem; }
.vsb-share a, .vsb-share button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--vsb-line);
    border-radius: 50%;
    background: #fff;
    color: #4b5563;
    cursor: pointer;
    transition: color .2s, border-color .2s;
}
.vsb-share a:hover, .vsb-share button:hover, .vsb-share .is-copied { border-color: var(--vsb-primary); color: var(--vsb-primary); }
.vsb-share svg { width: 1.0625rem; height: 1.0625rem; }
.vsb-share__copied:not(:empty) {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    padding: .25rem .5rem;
    border-radius: .375rem;
    background: var(--vsb-ink);
    color: #fff;
    font-size: .75rem;
    white-space: nowrap;
    transform: translateX(-50%);
}

/* Closing "Try VirtualStation" card */
.vsb-cta {
    display: grid;
    gap: 2rem;
    margin: 3rem 0;
    padding: 2rem 1.5rem;
    border: 1px solid var(--vsb-line);
    border-radius: 1.25rem;
    background: #fcfcfe;
}
@media (min-width: 720px) { .vsb-cta { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); align-items: center; padding: 2.5rem; } }
.vsb-cta__eyebrow { margin: 0 0 .625rem; color: var(--vsb-primary); font-size: .8125rem; font-weight: 600; }
.vsb-cta__title { margin: 0 0 .75rem; color: var(--vsb-ink); font-size: clamp(1.375rem, 3vw, 1.75rem); font-weight: 800; line-height: 1.2; letter-spacing: -.02em; }
.vsb-cta__text { margin: 0 0 1.5rem; color: #4b5563; font-size: 1rem; line-height: 1.65; }
.vsb-cta__actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.25rem; }
.vsb-cta__link { color: var(--vsb-ink); font-size: .9375rem; font-weight: 600; text-decoration: none; }
.vsb-cta__link:hover { color: var(--vsb-primary); }
.vsb-cta__note { margin: .875rem 0 0; color: var(--vsb-muted); font-size: .8125rem; }

.vsb-cta__preview { padding: 1.25rem; border-radius: 1rem; background-color: #f3f2fb; background-image: radial-gradient(#dcd9f2 1px, transparent 1px); background-size: 16px 16px; }
.vsb-mini { padding: 1rem; border: 1px solid #ebeaf5; border-radius: .875rem; background: #fff; box-shadow: 0 12px 24px -16px rgba(49, 46, 129, .35); font-family: Inter, sans-serif; }
.vsb-mini__head { display: flex; align-items: center; gap: .3rem; margin-bottom: .875rem; }
.vsb-mini__head span { width: 7px; height: 7px; border-radius: 50%; background: #e5e7eb; }
.vsb-mini__head strong { margin-left: .5rem; color: var(--vsb-ink); font-size: .8125rem; }
.vsb-mini__people { display: flex; flex-direction: column; gap: .625rem; margin: 0; padding: 0; list-style: none; }
.vsb-mini__people li { display: flex; align-items: center; gap: .625rem; color: var(--vsb-ink); font-size: .875rem; font-weight: 600; }
.vsb-mini__people b { width: 28px; height: 28px; border: 0; font-size: .6875rem; }
.vsb-mini__people em { margin-left: auto; padding: .125rem .5rem; border-radius: 999px; font-size: .6875rem; font-style: normal; font-weight: 600; }
.vsb-mini__people .is-meeting { background: #e0e7ff; color: #4338ca; }
.vsb-mini__people .is-focus { background: #fef3c7; color: #b45309; }
.vsb-mini__people .is-free { background: #d1fae5; color: #047857; }
.vsb-mini__note { margin-top: .875rem; padding: .625rem .75rem; border-radius: .625rem; background: #f9fafb; color: #4b5563; font-size: .8125rem; line-height: 1.45; }
.vsb-mini__note strong { display: block; margin-bottom: .125rem; color: var(--vsb-primary); font-size: .6875rem; letter-spacing: .06em; text-transform: uppercase; }


.vsb-related { padding: 4rem 1rem 6rem; background: #f9fafb; }
.vsb-related__inner { max-width: 80rem; margin: 0 auto; }
@media (min-width: 640px) { .vsb-related { padding-right: 1.5rem; padding-left: 1.5rem; } }
@media (min-width: 1024px) { .vsb-related { padding-right: 2rem; padding-left: 2rem; } }
.vsb-explore { display: grid; gap: 2rem; margin-top: 3.5rem; padding: 1.75rem; border: 1px solid var(--vsb-line); border-radius: 1.25rem; background: #fff; }
.vsb-related__title + .vsb-grid + .vsb-explore { margin-top: 3.5rem; }
.vsb-related__inner > .vsb-explore:first-child { margin-top: 0; }
@media (min-width: 768px) { .vsb-explore { grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 3rem; padding: 2rem 2.25rem; } }
.vsb-explore__title { margin: 0 0 1rem; color: var(--vsb-ink); font-size: 1.125rem; font-weight: 800; letter-spacing: -.01em; }
.vsb-tag__count { margin-left: .25rem; color: #9ca3af; font-weight: 500; }
.vsb-related__title { margin: 0 0 2rem; font-size: 1.75rem; font-weight: 800; letter-spacing: -.02em; }

@media (max-width: 1023px) {
    .vsb--single .vsb-layout { padding-top: 5.5rem; }
}

@media (prefers-reduced-motion: reduce) {
    .vsb-card, .vsb-card__media img, .vsb-btn { transition: none; }
    .vsb-card:hover, .vsb-card:hover .vsb-card__media img, .vsb-btn:hover { transform: none; }
}
