/* Blog Article Template Styles */

/* Reading Progress Bar */
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, #ef4444, #dc2626);
    z-index: 1000;
    transition: width 0.1s ease;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.breadcrumb li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #6b7280;
    font-size: 0.875rem;
}

.breadcrumb li:not(:last-child)::after {
    content: '/';
    color: #d1d5db;
}

.breadcrumb a {
    color: #6b7280;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: #ef4444;
}

/* Article Meta */
.article-meta-item {
    display: inline-flex;
    align-items: center;
    color: #6b7280;
    font-size: 0.875rem;
    font-weight: 500;
}

/* Article Title */
.article-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    color: #111827;
    margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
    .article-title {
        font-size: 2rem;
    }
}

.article-subtitle {
    font-size: 1.5rem;
    line-height: 1.6;
    color: #6b7280;
    font-weight: 400;
}

@media (max-width: 768px) {
    .article-subtitle {
        font-size: 1.125rem;
    }
}

/* Author */
.author-avatar-large {
    width: 4rem;
    height: 4rem;
    border-radius: 1rem;
    object-fit: cover;
}

.author-name-large {
    font-weight: 700;
    color: #111827;
    font-size: 1.125rem;
}

.author-bio {
    color: #6b7280;
    font-size: 0.875rem;
}

/* Share Buttons */
.share-button {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.5rem;
    background: #f3f4f6;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.3s ease;
}

.share-button:hover {
    background: #ef4444;
    color: white;
    transform: translateY(-2px);
}

/* Featured Image */
.article-featured-image {
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.article-featured-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Sidebar */
.article-sidebar {
    position: sticky;
    top: 6rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.sidebar-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

/* Table of Contents */
.toc {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    border: 2px solid #f3f4f6;
}

.toc-item {
    display: block;
    padding: 0.875rem 1.25rem;
    color: #6b7280;
    font-weight: 500;
    border-left: 3px solid transparent;
    margin-left: -2rem;
    padding-left: 2rem;
    transition: all 0.3s ease;
    font-size: 0.9375rem;
}

.toc-item:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.05);
    border-left-color: #ef4444;
}

.toc-item.active {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
    border-left-color: #ef4444;
    font-weight: 600;
}

/* Stats Box */
.stats-box {
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
    border-radius: 1rem;
    padding: 2rem;
    border: 2px solid #fecaca;
}

.stats-box-title {
    font-weight: 700;
    color: #111827;
    margin-bottom: 1rem;
    font-size: 1rem;
}

.stat-item {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(239, 68, 68, 0.1);
}

.stat-item:last-child {
    border-bottom: none;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 800;
    color: #ef4444;
}

.stat-label {
    font-size: 0.875rem;
    color: #6b7280;
}

/* Sidebar CTA */
.sidebar-cta {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-radius: 1rem;
    padding: 2rem;
    color: white;
    text-align: center;
}

.sidebar-cta h4 {
    margin-bottom: 0.75rem;
}

.sidebar-cta p {
    margin-bottom: 1.25rem;
    font-size: 0.9375rem;
    opacity: 0.95;
}

/* Article Content */
.article-content {
    background: white;
    border-radius: 1.5rem;
    padding: 4rem 4.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

@media (max-width: 1024px) {
    .article-content {
        padding: 3rem 3rem;
    }
}

@media (max-width: 768px) {
    .article-content {
        padding: 2rem 1.5rem;
    }
}

.article-content h2 {
    font-size: 2.25rem;
    font-weight: 700;
    color: #111827;
    margin-top: 4rem;
    margin-bottom: 2rem;
    scroll-margin-top: 6rem;
    line-height: 1.3;
}

.article-content h2:first-of-type {
    margin-top: 0;
}

.article-content h3 {
    font-size: 1.75rem;
    font-weight: 600;
    color: #111827;
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    line-height: 1.4;
}

.article-content p {
    font-size: 1.125rem;
    line-height: 1.9;
    color: #374151;
    margin-bottom: 2rem;
}

.lead-paragraph {
    font-size: 1.375rem;
    line-height: 1.85;
    color: #4b5563;
    margin-bottom: 3rem;
    padding: 1.5rem 0 1.5rem 1.5rem;
    border-left: 4px solid #ef4444;
    background: linear-gradient(90deg, rgba(239, 68, 68, 0.03), transparent);
    border-radius: 0 0.5rem 0.5rem 0;
}

/* Lists */
.article-list {
    list-style: none;
    padding: 0;
    margin: 2rem 0 2.5rem 0;
}

.article-list li {
    padding: 1rem 0 1rem 2.5rem;
    position: relative;
    font-size: 1.125rem;
    line-height: 1.8;
    color: #374151;
    margin-bottom: 0.5rem;
}

.article-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: #ef4444;
    font-weight: 700;
}

/* Blockquote */
.article-quote {
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
    border-left: 4px solid #ef4444;
    padding: 2.5rem 3rem;
    border-radius: 0 1rem 1rem 0;
    margin: 3rem 0;
    font-size: 1.375rem;
    line-height: 1.75;
    color: #374151;
    font-style: italic;
}

.article-quote cite {
    display: block;
    margin-top: 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #ef4444;
    font-style: normal;
}

.article-quote-large {
    font-size: 1.625rem;
    padding: 3rem 3.5rem;
    text-align: center;
    margin: 4rem 0;
}

/* Figures */
.article-figure {
    margin: 3.5rem 0;
}

.article-figure img {
    width: 100%;
    height: auto;
    border-radius: 1rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.article-figure figcaption {
    margin-top: 1.25rem;
    text-align: center;
    color: #6b7280;
    font-size: 0.9375rem;
    font-style: italic;
    padding: 0 1rem;
}

/* Info Boxes */
.info-box {
    display: flex;
    gap: 1.5rem;
    padding: 2rem 2.5rem;
    border-radius: 1rem;
    margin: 3rem 0;
}

.info-box-warning {
    background: #fef3c7;
    border: 2px solid #fbbf24;
}

.info-box-success {
    background: #d1fae5;
    border: 2px solid #10b981;
}

.info-box-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.info-box-warning .info-box-icon {
    color: #f59e0b;
}

.info-box-success .info-box-icon {
    color: #10b981;
}

.info-box-title {
    font-weight: 700;
    color: #111827;
    margin-bottom: 0.75rem;
    font-size: 1.125rem;
}

.info-box-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.info-box-list li {
    padding: 0.5rem 0;
    font-size: 0.9375rem;
    line-height: 1.6;
}

/* Metric Cards */
.metric-card {
    padding: 1.5rem;
    border-radius: 1rem;
    text-align: center;
    border: 2px solid;
}

.metric-card-red {
    background: #fef2f2;
    border-color: #fecaca;
}

.metric-card-yellow {
    background: #fef3c7;
    border-color: #fde68a;
}

.metric-card-gray {
    background: #f3f4f6;
    border-color: #e5e7eb;
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.metric-card-red .metric-value {
    color: #ef4444;
}

.metric-card-yellow .metric-value {
    color: #f59e0b;
}

.metric-card-gray .metric-value {
    color: #6b7280;
}

.metric-label {
    font-size: 0.875rem;
    color: #6b7280;
    font-weight: 500;
}

/* Timeline */
.timeline {
    position: relative;
    padding-left: 3rem;
    margin: 3rem 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 1rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, #ef4444, #dc2626);
}

.timeline-item {
    position: relative;
    margin-bottom: 2.5rem;
}

.timeline-marker {
    position: absolute;
    left: -2.5rem;
    width: 2rem;
    height: 2rem;
    border-radius: 0.5rem;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(239, 68, 68, 0.3);
}

.timeline-content {
    background: #f9fafb;
    padding: 1.5rem;
    border-radius: 1rem;
    border: 2px solid #e5e7eb;
}

.timeline-title {
    font-weight: 700;
    color: #111827;
    margin-bottom: 0.5rem;
}

/* Video Container */
.video-container {
    margin: 3.5rem 0;
    border-radius: 1rem;
    overflow: hidden;
    background: #000;
}

.video-placeholder {
    aspect-ratio: 16 / 9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1f2937, #111827);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.video-placeholder:hover {
    background: linear-gradient(135deg, #374151, #1f2937);
}

/* Comparison Table */
.comparison-table {
    margin: 2rem 0;
    overflow-x: auto;
}

.comparison-table table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.comparison-table th,
.comparison-table td {
    padding: 1.25rem 1.75rem;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
}

.comparison-table thead th {
    background: #f9fafb;
    font-weight: 700;
    color: #111827;
}

.comparison-table tbody tr:last-child td {
    border-bottom: none;
}

.comparison-table tbody tr:hover {
    background: #fef2f2;
}

/* Tip Cards */
.tip-card {
    background: white;
    padding: 1.5rem;
    border-radius: 1rem;
    border: 2px solid #f3f4f6;
    transition: all 0.3s ease;
}

.tip-card:hover {
    border-color: #ef4444;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.tip-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 0.875rem;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(220, 38, 38, 0.1));
    color: #ef4444;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.625rem;
    margin-bottom: 1.25rem;
}

.tip-title {
    font-weight: 700;
    color: #111827;
    margin-bottom: 0.5rem;
}

.tip-description {
    color: #6b7280;
    font-size: 0.9375rem;
    line-height: 1.6;
}

/* Article CTA */
.article-cta {
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
    border: 2px solid #fecaca;
    border-radius: 1.5rem;
    padding: 4rem 3rem;
    text-align: center;
    margin: 4rem 0;
}

.article-cta-content {
    max-width: 600px;
    margin: 0 auto;
}

/* Tags */
.article-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    padding: 3rem 0;
    border-top: 2px solid #e5e7eb;
    margin-top: 4rem;
}

.tag {
    background: #f3f4f6;
    color: #6b7280;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.tag:hover {
    background: #ef4444;
    color: white;
}

/* Author Card */
.author-card {
    display: flex;
    gap: 1.5rem;
    background: #f9fafb;
    padding: 2rem;
    border-radius: 1rem;
    margin-top: 3rem;
}

.author-card-avatar {
    width: 5rem;
    height: 5rem;
    border-radius: 1rem;
    object-fit: cover;
    flex-shrink: 0;
}

.author-card-name {
    font-weight: 700;
    color: #111827;
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.author-card-bio {
    color: #6b7280;
    line-height: 1.7;
    margin-bottom: 1.25rem;
    font-size: 1rem;
}

.author-social {
    width: 2.5rem;
    height: 2.5rem;
    background: white;
    border-radius: 0.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    transition: all 0.3s ease;
}

.author-social:hover {
    background: #ef4444;
    color: white;
    transform: translateY(-2px);
}

/* Related Articles */
.related-articles {
    margin-top: 4rem;
}

.related-article-card {
    background: white;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 2px solid #f3f4f6;
    transition: all 0.3s ease;
}

.related-article-card .p-4 {
    padding: 1.75rem;
}

.related-article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    border-color: #ef4444;
}

.related-article-image {
    width: 100%;
    height: auto;
    display: block;
}

/* Comments */
.comments-section {
    margin-top: 5rem;
    padding-top: 4rem;
    border-top: 2px solid #e5e7eb;
}

.comment-placeholder {
    background: #f9fafb;
    border-radius: 1rem;
    padding: 4rem 3rem;
    text-align: center;
    border: 2px dashed #e5e7eb;
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.4);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 100;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.5);
}

/* Responsive */
@media (max-width: 1024px) {
    .article-sidebar {
        position: relative;
        top: 0;
    }
}

@media (max-width: 768px) {
    .author-card {
        flex-direction: column;
        text-align: center;
    }

    .author-card-avatar {
        margin: 0 auto;
    }
}
