/* TARS catalog labels are separate links, not nested inside an article link. */
.tars-card-labels {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.tars-card-label {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 3px 10px;
    border: 1px solid #d8dcd9;
    border-radius: 6px;
    background: #f1f0ec;
    color: #53616b;
    font-size: 1.2rem;
    font-weight: 550;
    line-height: 1.5;
    text-decoration: none;
}

.tars-card-label:hover,
.tars-card-label:focus-visible {
    border-color: #086b67;
    color: #086b67;
    opacity: 1;
}

.tars-card-label:focus-visible,
.tars-series-intro a:focus-visible,
.gh-card-title a:focus-visible {
    outline: 2px solid #086b67;
    outline-offset: 3px;
}

.gh-card-link > .tars-card-image-link {
    flex-shrink: 0;
}

.tars-series-intro {
    margin-block: 56px 32px;
    padding: 30px;
    border: 1px solid #d8dcd9;
    border-radius: 12px;
    background: #fffdfa;
    color: #15242f;
}

.tars-series-eyebrow {
    margin-bottom: 10px;
    color: #086b67;
    font-size: 1.3rem;
    font-weight: 650;
}

.tars-series-intro h1 {
    margin-bottom: 16px;
    font-size: clamp(2.8rem, 4vw, 4rem);
    line-height: 1.3;
}

.tars-series-intro p,
.tars-series-intro li {
    font-size: 1.6rem;
    line-height: 1.8;
}

.tars-series-intro p {
    margin-bottom: 16px;
}

.tars-series-intro a {
    color: #086b67;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.tars-series-intro ol {
    padding-left: 24px;
    margin: 20px 0;
}

.tars-series-intro li + li {
    margin-top: 10px;
}

.tars-series-intro .tars-series-note {
    margin-bottom: 0;
    color: #65717a;
    font-size: 1.4rem;
}

@media (max-width: 767px) {
    .tars-series-intro {
        margin-top: 28px;
        padding: 22px 18px;
    }
}
/* Shared topic components; use the existing TARS design tokens. */
.tars-category-header {
    /* This is a stacked header, not Source's sixteen-column .gh-archive. */
    display: block;
    margin-block: 56px 24px;
    padding-bottom: 28px;
    border-bottom: 1px solid #d8dcd9;
}
.tars-category-header .gh-article-title {
    width: 100%;
    max-width: none;
    margin: 0 0 16px;
    font-size: clamp(3.2rem, 4vw, 4.8rem);
    line-height: 1.25;
}
.tars-category-header .gh-article-excerpt {
    width: 100%;
    max-width: none;
    margin: 0;
    font-size: 1.8rem;
    line-height: 1.7;
    color: #65717a;
}
.tars-series-heading {margin: 36px 0 22px;}
.tars-series-heading h2, .tars-series-heading h1 {margin: 12px 0;}
.tars-series-heading p, .tars-chapter p {color: #65717a; line-height: 1.65;}
/* Only topic overviews share this width; long-form article bodies retain
   Source's narrower reading canvas. Header and directory use the same gutters. */
.tars-topic-overview {--tars-topic-width: 960px;}
.tars-topic-overview > .gh-article-header {--content-width: var(--tars-topic-width);}
.tars-topic-overview > .gh-article-header .gh-article-excerpt {width: 100%; max-width: none;}
.tars-series-directory {--content-width: var(--tars-topic-width, 960px); margin-bottom: 45px;}
.tars-topic-main .tars-series-directory {margin-bottom: 24px;}
.tars-topic-main + .gh-footer {margin-top: 32px;}
.tars-topic-main .tars-chapter-group:last-child {margin-bottom: 0;}
.tars-chapter-group {margin: 22px 0 30px;}
.tars-chapter-section {font-size: 1.6rem; color: #086b67; border-bottom: 1px solid #d8dcd9; padding-bottom: 10px;}
.tars-chapter-grid {display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px;}
.tars-chapter {padding: 22px; margin: 12px 0; border: 1px solid #d8dcd9; border-radius: 12px; background: #fffdfa; min-width: 0;}
.tars-chapter-grid .tars-chapter {width: 100%; margin: 0;}
.tars-chapter {position: relative; transition: border-color .15s, box-shadow .15s;}
.tars-chapter:hover {border-color: #086b67; box-shadow: 0 3px 14px #102d380d;}
.tars-chapter-primary::after {content: ""; position: absolute; inset: 0; border-radius: 12px;}
.tars-chapter-preview {position: relative; z-index: 1; text-decoration: underline;}
.tars-chapter-action {margin-left: auto; color: #086b67;}
.tars-chapter:focus-within {outline: 2px solid #086b67; outline-offset: 3px;}
body {font-family: var(--tars-font); color: var(--tars-ink); background: var(--tars-bg);}
.tars-signin-prompt {font-size: 1.6rem; line-height: 1.7; color: var(--tars-muted);}
.tars-signin-prompt p {margin: 20px 0;}
.tars-signin-prompt .gh-button {margin-top: 8px;}
.gh-card-date[hidden] {display: none !important;}
.gh-button {background: var(--tars-accent);}
.gh-button-share {background: transparent; color: var(--tars-accent);}
.gh-article-header {padding-top: 48px;}
.tars-chapter h3 {font-size: 2rem; line-height: 1.45; margin: 0 0 12px;}
.tars-chapter p {font-size: 1.5rem; margin: 0 0 18px;}
.tars-chapter footer {display: flex; gap: 12px; justify-content: space-between; flex-wrap: wrap; font-size: 1.25rem; color: #65717a;}
.tars-chapter a, .tars-series-breadcrumb a {color: #086b67;}
.tars-series-breadcrumb {font-size: 1.4rem; line-height: 1.6; margin-bottom: 25px;}
[data-series-meta] {font-size: 1.25rem; color: #65717a; margin-right: 12px;}
.tars-topic-updates {margin: 28px 0 0; border: 1px solid var(--tars-line); border-radius: var(--tars-radius); background: var(--tars-paper); min-width: 0;}
.tars-topic-updates > summary {display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; padding: 14px 20px; color: var(--tars-accent); font-size: 1.5rem; font-weight: 600; line-height: 1.6; cursor: pointer; list-style: none;}
.tars-topic-updates > summary::-webkit-details-marker {display: none;}
.tars-topic-updates > summary:focus-visible {outline: 2px solid var(--tars-accent); outline-offset: 3px; border-radius: var(--tars-radius);}
.tars-update-count, .tars-update-toggle {font-size: 1.25rem; font-weight: 400;}
.tars-update-count {color: var(--tars-muted);}
.tars-update-toggle {flex-shrink: 0;}
.tars-update-collapse, .tars-topic-updates[open] .tars-update-expand {display: none;}
.tars-topic-updates[open] .tars-update-collapse {display: inline;}
.tars-topic-updates[open] > summary {border-bottom: 1px solid var(--tars-line);}
.tars-topic-updates-body {padding: 16px 20px 4px;}
.tars-update-note, .tars-update-empty {margin: 0 0 14px; color: var(--tars-muted); font-size: 1.3rem; line-height: 1.7;}
.tars-update-empty[hidden] {display: none;}
.tars-update-list {margin: 0; padding: 0; list-style: none;}
.tars-update-list li {display: grid; grid-template-columns: 105px minmax(0, 1fr); gap: 16px; padding: 16px 0; border-top: 1px solid var(--tars-line);}
.tars-update-meta {display: flex; flex-direction: column; gap: 4px; color: var(--tars-muted); font-size: 1.2rem; line-height: 1.7;}
.tars-update-title {color: var(--tars-accent); font-size: 1.5rem; font-weight: 600; line-height: 1.6;}
.tars-update-title:focus-visible {outline: 2px solid var(--tars-accent); outline-offset: 3px;}
.tars-update-description {margin: 8px 0 0; color: var(--tars-muted); font-size: 1.3rem; line-height: 1.7;}
.tars-update-description-label {color: var(--tars-ink);}
@media (max-width: 700px) {
    .tars-chapter-grid {grid-template-columns: 1fr;}
    .tars-chapter {padding: 18px;}
    .tars-topic-updates > summary {padding-inline: 16px;}
    .tars-topic-updates-body {padding-inline: 16px;}
    .tars-update-list li {grid-template-columns: 1fr; gap: 6px;}
    .tars-update-meta {flex-direction: row; gap: 12px;}
}
@media (max-width: 767px) {
    .tars-category-header {margin-top: 32px; padding-bottom: 22px;}
    .tars-category-header .gh-article-excerpt {font-size: 1.6rem;}
}
