/* Interactive Blog Enhancements for Dispute Resolution, Heritage, and Snagging Blogs */

/* Uniform Paragraph Spacing - Critical Fix */
.article-intro p,
.article-main p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.article-intro p:last-child,
.article-main p:last-child {
    margin-bottom: 0;
}

/* Heading Spacing */
.article-intro h2,
.article-main h2 {
    margin-top: 3rem;
    margin-bottom: 1.5rem;
}

.article-intro h3,
.article-main h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

/* List Spacing */
.article-intro ul,
.article-intro ol,
.article-main ul,
.article-main ol {
    margin-bottom: 1.5rem;
    margin-top: 1rem;
}

.article-intro li,
.article-main li {
    margin-bottom: 0.75rem;
    line-height: 1.7;
}

/* Reading Progress Bar */
.reading-progress {
    position: fixed;
    top: calc(var(--header-height, 80px) - 4px);
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-color, #ff6b6b), var(--secondary-color, #6b21a8));
    z-index: 1001;
    transition: width 0.1s ease;
}

/* Interactive Statistics Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2.5rem 0;
}

.stat-card {
    background: linear-gradient(135deg, var(--primary-color, #003d82), var(--secondary-color, #6b21a8));
    color: white;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 61, 130, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 8px 25px rgba(0, 61, 130, 0.3);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    display: block;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.95rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 1px;
}

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

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

.comparison-table th {
    background: linear-gradient(135deg, var(--primary-color, #003d82), var(--secondary-color, #6b21a8));
    color: white;
    padding: 1rem;
    text-align: left;
    font-weight: 600;
}

.comparison-table td {
    padding: 1rem;
    border-bottom: 1px solid #e0e0e0;
    transition: background 0.3s ease;
}

.comparison-table tr:hover td {
    background: #f8f9fa;
}

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

/* Interactive Process Cards */
.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2.5rem 0;
}

.process-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    border-left: 5px solid var(--secondary-color, #6b21a8);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    position: relative;
}

.process-card::before {
    content: attr(data-number);
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary-color, #003d82), var(--secondary-color, #6b21a8));
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.1rem;
}

.process-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 61, 130, 0.15);
    border-left-color: var(--accent-color, #ff6b6b);
}

.process-card h3 {
    color: var(--primary-color, #003d82);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.process-card p {
    color: var(--text-color, #333);
    line-height: 1.7;
    margin-bottom: 0;
}

/* Interactive FAQ Accordion */
.faq-accordion {
    margin: 2.5rem 0;
}

.faq-item {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    margin-bottom: 1rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 4px 15px rgba(0, 61, 130, 0.1);
}

.faq-question {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 1.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color, #003d82);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.3s ease;
}

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

.faq-question::after {
    content: '+';
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--secondary-color, #6b21a8);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question::after {
    content: '−';
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 1.5rem;
    transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-item.active .faq-answer {
    max-height: 800px;
    padding: 0 1.5rem 1.5rem 1.5rem;
}

.faq-answer p {
    color: var(--text-color, #333);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

/* Highlighted Info Boxes */
.info-box {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    padding: 2rem;
    border-radius: 10px;
    border-left: 5px solid var(--secondary-color, #6b21a8);
    margin: 2rem 0;
    position: relative;
    overflow: hidden;
}

.info-box::before {
    content: '💡';
    position: absolute;
    right: 1.5rem;
    top: 1.5rem;
    font-size: 3rem;
    opacity: 0.15;
}

.info-box h4 {
    color: var(--primary-color, #003d82);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.info-box p {
    color: var(--text-color, #333);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.info-box p:last-child {
    margin-bottom: 0;
}

/* Enhanced List Styling */
.checklist {
    list-style: none;
    padding: 0;
    margin: 2rem 0;
}

.checklist li {
    padding: 0.75rem 0.75rem 0.75rem 3rem;
    margin-bottom: 0.75rem;
    background: white;
    border-radius: 8px;
    border-left: 4px solid var(--secondary-color, #6b21a8);
    position: relative;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.checklist li:hover {
    transform: translateX(10px);
    box-shadow: 0 4px 15px rgba(0, 61, 130, 0.1);
}

.checklist li::before {
    content: '✓';
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background: var(--secondary-color, #6b21a8);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
}

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

.timeline-item {
    display: flex;
    gap: 2rem;
    margin-bottom: 2.5rem;
    position: relative;
    padding-left: 3rem;
}

.timeline-item::before {
    content: attr(data-step);
    position: absolute;
    left: 0;
    top: 0;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color, #003d82), var(--secondary-color, #6b21a8));
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    box-shadow: 0 4px 15px rgba(0, 61, 130, 0.3);
    z-index: 2;
}

.timeline-item::after {
    content: '';
    position: absolute;
    left: 24px;
    top: 50px;
    width: 2px;
    height: calc(100% + 20px);
    background: linear-gradient(180deg, var(--primary-color, #003d82), transparent);
}

.timeline-item:last-child::after {
    display: none;
}

.timeline-content {
    flex: 1;
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-content:hover {
    transform: translateX(10px);
    box-shadow: 0 4px 20px rgba(0, 61, 130, 0.15);
}

.timeline-content h3 {
    color: var(--primary-color, #003d82);
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
}

.timeline-content p {
    color: var(--text-color, #333);
    line-height: 1.7;
    margin-bottom: 0;
}

/* Scroll Animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .process-grid {
        grid-template-columns: 1fr;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .timeline-item {
        padding-left: 2.5rem;
    }
    
    .timeline-item::before {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .timeline-item::after {
        left: 19px;
    }
    
    .comparison-table {
        font-size: 0.9rem;
    }
    
    .process-card::before {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
}
