/* ========================================
   NEXTSET - SINGLE ARTICLE VIEW PAGE
   ======================================== */

.article-page {
    width: 100%;
    min-height: 70vh;
    overflow: hidden;
}

/* ========================================
   ARTICLE CONTAINER
   ======================================== */
.article-single {
    padding: 2rem 0 4rem;
}

/* Back link — top left */
.article-back-link {
    margin-bottom: 1.5rem;
}

.article-back-link a {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray);
    text-decoration: none;
    transition: color 0.15s;
}

.article-back-link a:hover {
    color: var(--black);
}

.article-container {
    max-width: 820px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ========================================
   HERO IMAGE
   ======================================== */
.article-hero-image {
    width: 100%;
    height: 280px;
    overflow: hidden;
    border-radius: var(--radius-lg);
    margin-bottom: 2.5rem;
}

.article-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* ========================================
   ARTICLE HEADER
   ======================================== */
.article-header {
    text-align: left;
    margin-bottom: 2rem;
}

.article-header h1 {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--black);
    margin-bottom: 1.25rem;
    line-height: 1.25;
    letter-spacing: -0.02em;
}

.article-meta-bar {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    color: var(--gray);
    font-size: 0.875rem;
    flex-wrap: wrap;
}

/* Kicker row — category badge · reading time, above the title */
.article-kicker {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}
.reading-time::before {
    content: "·";
    margin-right: 0.5rem;
    color: var(--gray);
    font-weight: 700;
}

/* Category Badge - inline in header (not positioned over image) */
.category-badge {
    display: inline-block;
    background-color: var(--orange);
    color: var(--white);
    padding: 0.3rem 0.85rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.reading-time {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ========================================
   ENGAGEMENT BAR (likes, views, share)
   ======================================== */
.article-engagement {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-top: 1.5rem;
}

.engage-btn,
.engage-stat {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.85rem;
    border: none;
    background: transparent;
    cursor: default;
    font-size: 0.875rem;
    color: var(--gray);
    font-family: inherit;
    white-space: nowrap;
}

.engage-btn {
    cursor: pointer;
    border-radius: var(--radius-full);
    transition: background 0.15s, color 0.15s;
}

.engage-btn:hover {
    background: var(--off-white);
    color: var(--black);
}

.engage-btn.like-btn.liked {
    color: var(--orange);
}

.engage-btn.like-btn.liked .engage-icon svg {
    fill: var(--orange);
    stroke: var(--orange);
}

.engage-icon {
    display: flex;
    align-items: center;
}

.engage-icon svg {
    width: 15px;
    height: 15px;
}

.engage-label {
    font-weight: 500;
}

.engage-divider {
    width: 1px;
    height: 18px;
    background: var(--border);
    flex-shrink: 0;
}

/* ========================================
   ARTICLE VIDEO EMBED
   ======================================== */
.article-video {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    margin-bottom: var(--space-2xl);
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--black);
}

.article-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ========================================
   ARTICLE BODY CONTENT
   ======================================== */
.article-body {
    font-size: 1.125rem;
    line-height: 1.75;
    color: #1a1a1a;
    margin-bottom: var(--space-2xl);
}

.article-body h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--black);
    margin-top: 2.75rem;
    margin-bottom: 0.75rem;
    padding-left: 1rem;
    border-left: 5px solid var(--orange);
    letter-spacing: -0.015em;
    line-height: 1.3;
}

.article-body h3 {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--black);
    margin-top: 2rem;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.article-body p {
    font-size: 1.125rem;
    line-height: 1.75;
    margin-bottom: 1.35rem;
}


.article-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    margin: 2rem 0;
    display: block;
}

.article-body ul,
.article-body ol {
    margin: 1.25rem 0 1.5rem;
    padding-left: 1.6rem;
    list-style: disc;
}

.article-body ol {
    list-style: decimal;
}

.article-body li {
    font-size: 1.125rem;   /* identical to paragraphs — overrides the global `li` size */
    line-height: 1.75;
    margin-bottom: 0.6rem;
}

.article-body strong {
    font-weight: 700;
    color: var(--black);
}

.article-body a {
    color: var(--orange);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.article-body a:hover {
    opacity: 0.8;
}

/* Pull-quote / blockquote */
.article-body blockquote {
    margin: 2rem 0;
    padding: 1.25rem 1.5rem;
    border-left: 4px solid var(--orange);
    background: var(--off-white);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-size: 1.05rem;
    color: #333;
    font-style: italic;
}

.article-body blockquote p {
    margin: 0;
}

/* Citation References */
.article-body sup a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

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

/* Sources Section */
.article-body .sources {
    margin-top: var(--space-2xl);
    padding-top: var(--space-xl);
    border-top: 2px solid var(--border-light);
}

.article-body .sources h3 {
    font-size: var(--fs-h3);
    color: var(--black);
    margin-bottom: var(--space-md);
}

.article-body .sources ol {
    margin: 0;
    padding-left: var(--space-lg);
}

.article-body .sources li {
    margin-bottom: 0.5rem;
    font-size: var(--fs-small);
    color: var(--gray);
}

.article-body .sources li a {
    color: var(--primary);
}

/* ========================================
   ARTICLE FOOTER
   ======================================== */
.article-footer {
    padding-top: var(--space-xl);
    border-top: 1px solid var(--border);
}

/* Author byline */
.article-byline {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-bottom: var(--space-lg);
}

.byline-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--dark-blue);
    color: var(--white);
    font-weight: 700;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.byline-info {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.byline-name {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--black);
}

.byline-date {
    font-size: 0.8125rem;
    color: var(--gray);
}

.article-tags {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: var(--space-lg);
    margin-top: var(--space-lg);
}

.tags-label {
    font-weight: 600;
    color: var(--black);
}

.tag {
    background-color: var(--border-light);
    padding: 0.4rem 1rem;
    border-radius: var(--radius-full);
    font-size: var(--fs-small);
    color: var(--gray);
}


/* ========================================
   RELATED ARTICLES SECTION
   ======================================== */
.related-articles {
    background-color: var(--off-white);
    padding: 4rem 0;
}

.related-articles h2 {
    text-align: center;
    margin-bottom: var(--space-xl);
    color: var(--black);
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-xl);
}

.related-card {
    background-color: var(--white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 4px 12px var(--shadow-md);
    transition: all var(--transition-base);
}

.related-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px var(--shadow-lg);
}

.related-card a {
    text-decoration: none;
    color: var(--black);
    display: block;
}

.related-card img,
.related-card .placeholder-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.related-card .placeholder-image {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    background: linear-gradient(135deg, var(--light-bg) 0%, var(--border) 100%);
}

.related-card h3 {
    padding: var(--space-md);
    font-size: var(--fs-h3);
    color: var(--black);
}

.related-meta {
    padding: 0 var(--space-md) var(--space-md);
    color: var(--gray);
    font-size: var(--fs-small);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.related-meta .icon-small {
    margin-top: -1px;
}

/* ========================================
   RESPONSIVE DESIGN - MOBILE FIRST
   ======================================== */

/* Extra Small Mobile (< 480px) */
@media screen and (max-width: 479px) {
    .article-header h1 {
        font-size: 1.65rem;
        letter-spacing: -0.01em;
    }
    .article-body {
        font-size: 1rem;
    }
}

/* Mobile (480px - 768px) */
@media screen and (min-width: 480px) and (max-width: 768px) {
    .article-header h1 {
        font-size: 1.9rem;
    }
}

/* Tablet (769px+) */
@media screen and (min-width: 769px) {
    /* no overrides needed */
}

/* Desktop (1025px+) */
@media screen and (min-width: 1025px) {
    .article-body {
        font-size: 1.125rem;
    }

    .article-header h1 {
        font-size: 2.625rem;
    }
}

/* Glossary auto-links */
.article-body .glossary-link {
    color: var(--orange);
    text-decoration: underline;
    text-decoration-style: dotted;
    text-underline-offset: 3px;
    font-weight: inherit;
}

.article-body .glossary-link:hover {
    text-decoration-style: solid;
}

/* FAQ Section */
.article-faq {
    margin: 2.5rem 0 1.5rem;
    border-top: 2px solid var(--border);
    padding-top: 2rem;
}

.article-faq h2 {
    font-size: var(--font-xl);
    font-weight: 700;
    margin-bottom: 1.25rem;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.faq-entry {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    width: 100%;
    padding: 1rem 1.25rem;
    background: var(--off-white);
    border: none;
    cursor: pointer;
    text-align: left;
    font-size: var(--font-base);
    font-weight: 600;
    color: var(--black);
    transition: background 0.15s;
}

.faq-question:hover {
    background: #f0f0f0;
}

.faq-question[aria-expanded="true"] {
    background: var(--black);
    color: var(--white);
}

.faq-question[aria-expanded="true"] .faq-chevron svg {
    transform: rotate(180deg);
    stroke: var(--white);
}

.faq-chevron {
    flex-shrink: 0;
    transition: transform 0.2s;
}

.faq-chevron svg {
    display: block;
    transition: transform 0.2s;
}

.faq-answer {
    padding: 1rem 1.25rem;
    background: var(--white);
    border-top: 1px solid var(--border);
}

.faq-answer p {
    margin: 0;
    color: var(--gray-dark);
    line-height: 1.65;
    font-size: var(--font-base);
}
