/* Lightbox */
.lightbox-trigger {
    cursor: zoom-in;
}

#lightbox-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.75);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

#lightbox-overlay.active {
    display: flex;
}

#lightbox-content {
    position: relative;
    background: #fff;
    border-radius: 1rem;
    border: 2px dashed #4c4c7c;
    padding: 2rem;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    overflow: auto;
}

#lightbox-close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: none;
    border: 2px dashed #4c4c7c;
    border-radius: 50%;
    width: 2rem;
    height: 2rem;
    font-size: 1rem;
    cursor: pointer;
    color: #4c4c7c;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

#lightbox-close:hover {
    background-color: #4c4c7c;
    color: #fff;
}

#lightbox-img {
    max-width: 100%;
    max-height: 70vh;
    border-radius: 0.5rem;
    object-fit: contain;
}

#lightbox-caption {
    font-size: 0.9rem;
    font-style: italic;
    color: #555;
    text-align: center;
    width: auto;
}

/* Blog entry page layout */
.blog-entry {
    width: 100%;
    box-sizing: border-box;
    padding: 1rem 1.5rem 1.5rem 4.5rem;
    line-height: 1.75;
    background-color: #faf9f0;
    background-image:
        linear-gradient(90deg,
            transparent 3.5rem,
            rgba(171, 171, 242, 0.6) 3.5rem,
            rgba(171, 171, 242, 0.6) calc(3.5rem + 1px),
            transparent calc(3.5rem + 1px)
        ),
        repeating-linear-gradient(
            transparent 0px,
            transparent 27px,
            rgba(171, 171, 242, 0.35) 27px,
            rgba(171, 171, 242, 0.35) 28px
        );
}

/* Tip callout for blog entries */
.tip {
    background-color: rgba(171, 171, 242, 0.15);
    border-left: 3px solid #4c4c7c;
    border-radius: 0 0.5rem 0.5rem 0;
    padding: 0.6rem 1rem;
    margin: 1rem 0;
    font-size: 0.9rem;
    color: #4c4c7c;
}

.tip::before {
    content: "✦ tip: ";
    font-weight: bold;
    text-transform: lowercase;
}

/* Blog index cards */
.blog-entry-card {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1rem;
    border-radius: 1rem;
    border: 1px dashed #4c4c7c;
    cursor: pointer;
    background-color: rgba(171, 171, 242, 0.05);
    transition: box-shadow 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.blog-entry-card:hover {
    box-shadow: 0 4px 12px rgba(76, 76, 124, 0.15);
    border-color: #ababf2;
    background-color: rgba(171, 171, 242, 0.12);
}

.entry-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.entry-card-date {
    font-size: 0.78rem;
    color: #888;
    font-style: italic;
}

.entry-card-icon {
    width: 1.2rem;
    height: 1.2rem;
}

.entry-card-title {
    font-family: 'Bitcount', monospace;
    font-weight: 300;
    font-size: 1.5rem;
    text-transform: lowercase;
    text-align: left;
    align-self: flex-start;
    margin: 0;
    color: #4c4c7c;
}

.entry-card-snippet {
    font-size: 0.88rem;
    color: #444;
    line-height: 1.6;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.entry-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 0.25rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.entry-card-read-more {
    align-self: flex-end;
    white-space: nowrap;
}

.blog-image {
    width: 300px;
    height: auto;
    display: block;
}
