/* ---- Posts grid ---- */

main.posts-list {
    max-width: 1050px;
}

.posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.post-card {
    display: block;
    text-decoration: none !important;
    color: inherit !important;
    background: #f9f9f9;
    border: 1px solid #e8e8e8;
    border-radius: 4px;
    padding: 1.2rem 1rem;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
    text-align: left;
}

.post-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    color: inherit !important;
}

.post-card h4 {
    font-size: 1.7rem;
    margin: 0 0 0.25rem;
    line-height: 1.3;
}

.post-card h5 {
    font-size: 1.3rem;
    color: #888;
    margin: 0 0 0.5rem;
}

.post-card-summary {
    font-size: 1.3rem;
    color: #555;
    margin: 0.5rem 0 0.75rem;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Posts tag bar */

.posts-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0 1.75rem;
    padding: 0.9rem 1rem;
    background: #f4f4f4;
    border-radius: 4px;
}

.posts-tag {
    display: inline-block;
    background: white;
    border: 1px solid #ccc;
    color: #444 !important;
    padding: 0.2rem 0.7rem;
    border-radius: 20px;
    font-size: 1.2rem;
    font-style: italic;
    text-decoration: none !important;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.posts-tag::before {
    content: "#";
}

.posts-tag:hover,
.posts-tag-active {
    background: var(--accent);
    color: white !important;
    border-color: var(--accent);
}

/* Mobile: single-column vertical list */
@media (max-width: 700px) {
    main.posts-list {
        max-width: 100%;
    }

    .posts-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .post-card {
        background: transparent;
        border: none;
        border-bottom: 1px solid #e0e0e0;
        border-radius: 0;
        padding: 12px 0;
    }
}

/* ---- Recordings grid ---- */

main.recordings-list {
    max-width: 1000px;
}

.recordings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.recording-card {
    display: block;
    text-decoration: none !important;
    color: inherit !important;
    transition: transform 0.18s ease, opacity 0.18s ease;
}

.recording-card:hover {
    transform: translateY(-3px);
    opacity: 0.85;
}

.recording-card img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    display: block;
    border-radius: 3px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.recording-card h4 {
    font-size: 1.84rem;
    margin: 0.5rem 0 0.1rem;
    line-height: 1.3;
}

.recording-card h5 {
    font-size: 1.5rem;
    margin: 0;
    line-height: 1.3;
}

/* Mobile: vertical list */
@media (max-width: 600px) {
    .recordings-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .recording-card {
        display: flex;
        align-items: center;
        gap: 1rem;
        padding: 12px 0;
        border-bottom: 1px solid #e0e0e0;
    }

    .recording-card img {
        width: 70px;
        height: 70px;
        flex-shrink: 0;
        aspect-ratio: auto;
        border-radius: 2px;
    }

    .recording-card-info {
        flex: 1;
    }

    .recording-card h4 {
        margin-top: 0;
    }
}
