/* Journal styles consistent with main site theme */
:root {
    --primary-color: #007bff;
    --text-color: #333;
    --background-color: #f8f9fa;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    padding-top: 2rem;
}
.journal-entry {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1rem;
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
}

/* Header styles */
.journal-header {
    margin-bottom: 2rem;
    border-bottom: 2px solid #eee;
    padding-bottom: 1rem;
    position: relative;
}

.journal-title {
    font-size: 2rem;
    font-weight: 300;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.journal-metadata {
    color: var(--text-color);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: flex;
    gap: 1rem;
    align-items: center;
    opacity: 0.8;
}

/* Content styles */
.journal-content {
    line-height: 1.6;
    font-size: 1rem;
    color: var(--text-color);
}

.journal-content p {
    margin-bottom: 1.5rem;
}

.journal-content h2 {
    font-size: 1.8rem;
    font-weight: 300;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.journal-content h3 {
    font-size: 1.5rem;
    font-weight: 300;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

/* Image handling */
.journal-content img {
    max-width: 100%;
    height: auto;
    margin: 2rem auto;
    display: block;
}

.image-caption {
    text-align: center;
    color: var(--text-color);
    font-size: 0.9rem;
    margin-top: -1.5rem;
    margin-bottom: 2rem;
    opacity: 0.8;
}

/* Code formatting */
.journal-content code {
    background-color: #f1f3f5;
    padding: 0.2em 0.4em;
    border-radius: 3px;
    font-size: 0.9em;
    font-family: monospace;
}

/* Navigation */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 2rem 0 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: #0056b3; /* Slightly darker than primary for hover */
    text-decoration: none;
}

/* Article footer */
.article-footer {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 2px solid #eee;
}

/* Tags */
.tags {
    margin-top: 1rem;
}

.tag {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    margin: 0.2rem;
    background-color: var(--background-color);
    border: 1px solid var(--primary-color);
    border-radius: 3px;
    color: var(--primary-color);
    font-size: 0.9rem;
}

/* Responsive design */
@media (max-width: 991px) {
    .journal-title {
        font-size: 1.8rem;
    }
    
    .journal-content {
        font-size: 1rem;
    }
    
    .journal-content h2 {
        font-size: 1.6rem;
    }
    
    .journal-content h3 {
        font-size: 1.3rem;
    }
}

@media (max-width: 575px) {
    .journal-entry {
        padding: 0 1rem;
    }
    
    .journal-title {
        font-size: 1.6rem;
    }
    
    .journal-content h2 {
        font-size: 1.4rem;
    }
    
    .journal-content h3 {
        font-size: 1.2rem;
    }
}

.smart-chip {
    background-color: #f1f3f5;
    border-radius: 16px;
    padding: 1px 10px;
    text-decoration: none;
    color: inherit;
    display: inline-flex;
    align-items: center;
    transition: background-color 0.2s;
}

.smart-chip:hover {
    background-color: #e9ecef;
    text-decoration: none;
}

/* Email chip */
a[href^="mailto:"].smart-chip::before {
    content: "✉";
    margin-right: 6px;
    font-size: 0.9em;
}

/* Strava chip */
a[href*="strava.com"].smart-chip::before {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 6px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23FC4C02' d='M15.387 17.944l-2.089-4.116h-3.065L15.387 24l5.15-10.172h-3.066m-7.008-5.599l2.836 5.598h4.172L10.463 0l-7 13.828h4.169'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

/* GitHub chip */
a[href*="github.com"].smart-chip::before {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 6px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23333333' d='M12 0C5.37 0 0 5.37 0 12c0 5.31 3.435 9.795 8.205 11.385.6.105.825-.255.825-.57 0-.285-.015-1.23-.015-2.235-3.015.555-3.795-.735-4.035-1.41-.135-.345-.72-1.41-1.23-1.695-.42-.225-1.02-.78-.015-.795.945-.015 1.62.87 1.845 1.23 1.08 1.815 2.805 1.305 3.495.99.105-.78.42-1.305.765-1.605-2.67-.3-5.46-1.335-5.46-5.925 0-1.305.465-2.385 1.23-3.225-.12-.3-.54-1.53.12-3.18 0 0 1.005-.315 3.3 1.23.96-.27 1.98-.405 3-.405s2.04.135 3 .405c2.295-1.56 3.3-1.23 3.3-1.23.66 1.65.24 2.88.12 3.18.765.84 1.23 1.905 1.23 3.225 0 4.605-2.805 5.625-5.475 5.925.435.375.81 1.095.81 2.22 0 1.605-.015 2.895-.015 3.3 0 .315.225.69.825.57A12.02 12.02 0 0024 12c0-6.63-5.37-12-12-12z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.table-wrapper {
    overflow-x: auto;
    margin: 2rem 0;
}

.table-wrapper table {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
}

.table-wrapper th,
.table-wrapper td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.table-wrapper th {
    background-color: #f8f9fa;
    font-weight: 600;
    border-bottom: 2px solid #dee2e6;
}

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

.table-wrapper tr:hover {
    background-color: #f8f9fa;
}

/* Code block styling */
.code-block {
    background-color: #f9f9f9;
    border-left: 4px solid #007bff;
    padding: 1rem;
    border-radius: 4px;
    margin: 1.5rem 0;
    overflow-x: auto;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.75em;
    white-space: pre-wrap;
}

/* Link styling consistent with index */
.journal-content a {
    color: black;
    text-decoration: underline;
}