/* Common Blog Styles - Unified Theme */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f5f5f5;
}

article {
    max-width: 900px;
    margin: 0 auto;
    background: white;
    padding: 60px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

/* Back to home link */
.back-link {
    display: inline-block;
    margin-bottom: 20px;
    color: #666;
    text-decoration: none;
    font-size: 0.95em;
}

.back-link:hover {
    color: #333;
}

/* Typography */
h1 {
    font-size: 2.5em;
    margin-bottom: 0.3em;
    color: #1a1a1a;
    line-height: 1.2;
}

h2 {
    font-size: 1.8em;
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    color: #2c3e50;
}

h3 {
    font-size: 1.3em;
    margin-top: 1.2em;
    margin-bottom: 0.5em;
    color: #34495e;
}

h4 {
    font-size: 1.1em;
    margin-top: 1em;
    margin-bottom: 0.5em;
    color: #34495e;
}

p {
    margin-bottom: 1em;
    text-align: justify;
}

.meta {
    color: #666;
    margin-bottom: 2em;
    padding-bottom: 1em;
    border-bottom: 2px solid #e0e0e0;
}

.lede {
    font-size: 1.2em;
    color: #555;
    margin-bottom: 1.5em;
    font-style: italic;
}

/* Lists */
ul, ol {
    margin-left: 2em;
    margin-bottom: 1em;
}

li {
    margin-bottom: 0.5em;
}

/* Links */
a {
    color: #3498db;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Special Content Boxes */
.concept-card {
    background: #f8f9fa;
    border-left: 4px solid #3498db;
    padding: 20px;
    margin: 20px 0;
}

.concept-card h3 {
    margin-top: 0;
    color: #2c3e50;
}

.example-box {
    background: #e8f4f8;
    padding: 15px;
    margin: 10px 0;
    border-radius: 5px;
}

.result-box {
    background: #fff9e6;
    border-left: 4px solid #f39c12;
    padding: 20px;
    margin: 20px 0;
}

.result-box.strong {
    background: #e8f8e8;
    border-left-color: #27ae60;
}

.result-box.weak {
    background: #ffe8e8;
    border-left-color: #e74c3c;
}

.key-insight {
    background: #34495e;
    color: white;
    padding: 25px;
    margin: 30px 0;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.key-insight h3 {
    color: white;
    margin-top: 0;
}

.methodology {
    background: #f0f0f0;
    padding: 20px;
    margin: 20px 0;
    border-radius: 5px;
    font-size: 0.95em;
}

.note-box {
    background: #fff3cd;
    border: 1px solid #ffc107;
    padding: 15px;
    margin: 20px 0;
    border-radius: 4px;
}

.disclaimer {
    background: #fff3cd;
    border: 1px solid #ffc107;
    padding: 15px;
    margin: 30px 0;
    border-radius: 4px;
    font-size: 0.95em;
}

/* Charts */
.chart-container {
    margin: 30px 0;
    padding: 20px;
    background: #fafafa;
    border-radius: 8px;
}

.chart-wrapper {
    position: relative;
    height: 400px;
    margin-bottom: 15px;
}

/* Tables */
.table-wrapper {
    overflow-x: auto;
    margin: 20px 0;
    -webkit-overflow-scrolling: touch;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    font-size: 0.95em;
    min-width: 600px;
}

.data-table th {
    background: #34495e;
    color: white;
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

.data-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #ddd;
}

.data-table tr:nth-child(even) {
    background: #f8f9fa;
}

.data-table tr:hover {
    background: #e8f4f8;
}

.stat-highlight {
    font-weight: bold;
    color: #27ae60;
}

.stat-highlight.negative {
    color: #e74c3c;
}

.stat-highlight.neutral {
    color: #95a5a6;
}

/* Expandable Details */
details {
    margin: 15px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 4px;
}

summary {
    cursor: pointer;
    font-weight: 600;
    color: #2c3e50;
}

summary:hover {
    color: #3498db;
}

/* References */
.reference-section {
    margin-top: 3em;
    padding-top: 2em;
    border-top: 2px solid #e0e0e0;
}

.reference-section h2 {
    font-size: 1.3em;
}

.reference-section ol {
    font-size: 0.9em;
    line-height: 1.8;
}

/* Responsive */
@media (max-width: 768px) {
    article {
        padding: 30px 20px;
    }

    h1 {
        font-size: 2em;
    }

    h2 {
        font-size: 1.5em;
    }

    .chart-wrapper {
        height: 300px;
    }
    
    .data-table {
        font-size: 0.85em;
        min-width: 500px;
    }

    .data-table th, .data-table td {
        padding: 8px 6px;
        font-size: 0.9em;
    }

    .table-wrapper {
        margin: 15px -20px;
        padding: 0 20px;
    }
}
