/* ── Article Shared Styles ── */
/* Loaded by all article pages alongside /main.css */

/* Body / layout */
body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* ── Back Link ── */
.back-link {
    max-width: 720px;
    margin: 0 auto;
    padding: 100px 20px 20px;
}

.back-link a {
    color: var(--gray);
    text-decoration: none;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: gap 0.15s ease, color 0.15s ease;
}

.back-link a:hover {
    color: var(--black);
    gap: 10px;
}

/* ── Article Header ── */
.article-header {
    background: var(--white);
    padding: 20px 20px 40px;
    border-bottom: 1px solid #eee;
}

.article-header-inner {
    max-width: 720px;
    margin: 0 auto;
}

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

.article-category {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--black);
    background: var(--yellow);
    border-radius: 20px;
    padding: 3px 10px;
}

.article-read-time {
    font-size: 12px;
    color: var(--gray);
}

.article-read-time::before {
    content: '·';
    margin-right: 10px;
    color: var(--gray);
}

.article-header h1 {
    font-weight: 500;
    font-size: 52px;
    line-height: 62px;
    margin: 0 0 20px 0;
    font-family: 'Helvetica Neue', sans-serif;
}

.article-byline {
    font-size: 14px;
    color: var(--gray);
}

.article-byline .author {
    color: var(--black);
}

/* Sources block (semaglutide-guide) */
.article-sources {
    font-size: 14px;
    line-height: 22px;
    color: var(--gray);
    margin-top: 12px;
}

.article-sources p {
    margin: 0 0 8px 0;
    font-size: 14px;
    line-height: 22px;
    color: var(--gray);
}

.article-sources ul {
    margin: 0;
    padding-left: 20px;
}

.article-sources li {
    margin-bottom: 4px;
    font-size: 14px;
    line-height: 22px;
    color: var(--gray);
}

.article-sources a {
    color: var(--blue);
    text-decoration: underline;
}

.article-sources a:hover {
    text-decoration: none;
}

/* ── Article Content Typography ── */
.article-content {
    max-width: 720px;
    margin: 0 auto;
    padding: 40px 20px 60px;
}

.article-content h2 {
    font-weight: 500;
    font-size: 28px;
    line-height: 36px;
    margin: 52px 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--yellow);
    font-family: 'Helvetica Neue', sans-serif;
}

.article-content h3 {
    font-weight: 600;
    font-size: 20px;
    line-height: 28px;
    margin: 36px 0 14px 0;
    font-family: 'Helvetica Neue', sans-serif;
}

.article-content p {
    font-size: 18px;
    line-height: 32px;
    color: #333;
    margin: 0 0 28px 0;
}

.article-content ul,
.article-content ol {
    margin: 0 0 28px 0;
    padding-left: 24px;
}

/* Styled ordered lists (steps) */
.article-content ol:not(.article-references) {
    list-style: none;
    padding-left: 0;
    counter-reset: article-counter;
}

.article-content ol:not(.article-references) > li {
    counter-increment: article-counter;
    padding-left: 36px;
    position: relative;
}

.article-content ol:not(.article-references) > li::before {
    content: counter(article-counter);
    position: absolute;
    left: 0;
    top: 3px;
    width: 24px;
    height: 24px;
    background: var(--yellow);
    border-radius: 50%;
    font-size: 13px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--black);
    line-height: 1;
}

/* Plain references list */
.article-content ol.article-references {
    list-style: decimal;
    padding-left: 20px;
}

.article-content ol.article-references > li {
    padding-left: 4px;
    font-size: 14px;
    line-height: 22px;
    color: var(--gray);
    margin-bottom: 6px;
}

.article-content li {
    font-size: 18px;
    line-height: 32px;
    color: #333;
    margin-bottom: 12px;
}

.article-content strong {
    color: #111;
}

.article-content a {
    color: var(--blue);
    text-decoration: underline;
}

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

/* Hero image */
.article-content > img:first-child,
.article-content img.hero-image {
    width: 100%;
    aspect-ratio: 16 / 7;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 40px;
    display: block;
}

/* ── Comparison Table ── */
.article-content .table-wrapper {
    border-radius: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid #e5e5e5;
    margin: 0 0 32px 0;
}

.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    font-size: 16px;
    line-height: 26px;
}

.article-content table th {
    background: var(--light-gray);
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--black);
    padding: 12px 16px;
    text-align: left;
    border-bottom: 2px solid #e5e5e5;
}

.article-content table th:first-child {
    border-left: 3px solid var(--yellow);
}

.article-content table td {
    padding: 14px 16px;
    border-bottom: 1px solid #e5e5e5;
    color: #333;
    vertical-align: top;
    font-size: 15px;
    line-height: 24px;
}

.article-content table td:first-child {
    font-weight: 600;
    color: var(--black);
    border-left: 3px solid var(--yellow);
}

.article-content table tr:nth-child(even) td {
    background: #fafafa;
}

.article-content table tr:last-child td {
    border-bottom: none;
}

/* ── Callout Box ── */
.callout-box {
    background: var(--yellow);
    border-radius: 20px;
    padding: 28px 32px;
    margin: 48px 0;
    border-left: 4px solid rgba(0, 0, 0, 0.12);
}

.callout-box h2 {
    font-size: 21px;
    line-height: 28px;
    color: var(--black);
    font-weight: 700;
    margin: 0 0 16px 0;
    border-bottom: none;
    padding-bottom: 0;
}

.callout-box p {
    font-size: 15px;
    line-height: 25px;
    color: var(--black);
    margin: 0;
    padding: 8px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.07);
}

.callout-box p:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

/* ── Disclaimer ── */
.article-disclaimer {
    font-size: 13px;
    line-height: 21px;
    color: var(--gray);
    border-top: 1px solid #e5e5e5;
    padding-top: 24px;
    margin-top: 48px;
}

/* ── Related Resources ── */
.related-resources {
    list-style: none;
    padding: 0;
    margin: 0 0 28px 0;
}

.related-resources li {
    margin-bottom: 0;
}

.related-resources li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    border: 1px solid #e5e5e5;
    border-radius: 10px;
    margin-bottom: 8px;
    color: var(--black);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    line-height: 22px;
    transition: background 0.15s, border-color 0.15s;
}

.related-resources li a::after {
    content: '→';
    flex-shrink: 0;
    margin-left: 12px;
    color: var(--gray);
    transition: transform 0.15s, color 0.15s;
}

.related-resources li a:hover {
    background: var(--light-gray);
    border-color: #ccc;
    text-decoration: none;
}

.related-resources li a:hover::after {
    transform: translateX(3px);
    color: var(--black);
}

/* ── CTA Section ── */
.article-cta {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 20px 80px;
}

.cta-card {
    background: var(--yellow);
    border-radius: 24px;
    padding: 56px 48px;
    text-align: center;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

.cta-card h3 {
    font-weight: 500;
    font-size: 32px;
    line-height: 40px;
    margin: 0 0 14px 0;
    color: var(--black);
    font-family: 'Helvetica Neue', sans-serif;
}

.cta-card p {
    font-size: 16px;
    line-height: 26px;
    color: rgba(0, 0, 0, 0.6);
    margin: 0 0 32px 0;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-primary {
    background-color: var(--black);
    color: var(--white);
    border: none;
    border-radius: 25px;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    font-family: 'Helvetica Neue', sans-serif;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 40px;
    box-sizing: border-box;
    transition: background-color 0.3s;
}

.btn-primary img {
    width: 14px;
    height: 16px;
    display: block;
}

.btn-secondary {
    background-color: var(--white);
    color: var(--black);
    border: 2px solid var(--black);
    border-radius: 25px;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    font-family: 'Helvetica Neue', sans-serif;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    box-sizing: border-box;
    transition: background-color 0.2s;
}

.btn-primary:hover {
    background-color: #333;
}

.btn-secondary:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

/* ── Mobile Responsive ── */
@media (max-width: 599px) {
    .back-link {
        padding: 80px 20px 16px;
    }

    .article-header {
        padding: 16px 20px 32px;
    }

    .article-header h1 {
        font-size: 34px;
        line-height: 42px;
    }

    .article-content h2 {
        font-size: 24px;
        line-height: 32px;
        margin: 40px 0 16px 0;
    }

    .article-content h3 {
        font-size: 18px;
        line-height: 26px;
    }

    .article-content p,
    .article-content li {
        font-size: 16px;
        line-height: 28px;
    }

    /* Let wide tables keep a legible width and scroll inside the wrapper
       instead of cramming columns down to an unreadable size */
    .article-content table {
        min-width: 480px;
    }

    .article-content table th,
    .article-content table td {
        padding: 10px 12px;
        font-size: 14px;
        line-height: 20px;
    }

    /* Hero image: 16/7 is a thin band on a phone - give it more height */
    .article-content > img:first-child,
    .article-content img.hero-image {
        aspect-ratio: 3 / 2;
        margin-bottom: 28px;
    }

    .callout-box {
        padding: 22px 20px;
    }

    .callout-box h2 {
        font-size: 18px;
    }

    .callout-box p {
        font-size: 14px;
        line-height: 23px;
    }

    .cta-card {
        padding: 36px 24px;
    }

    .cta-card h3 {
        font-size: 24px;
        line-height: 32px;
    }
}
