/* Guides listing: post cards (cover on top, meta + title + summary below).
   The whole card is the link — hover raises the card and tints the title. */

.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.post-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    transition: border-color 140ms ease, box-shadow 140ms ease;
}

.post-card:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow-raised);
}

.post-card:hover .post-card-title {
    color: var(--accent);
}

.post-card-media {
    display: block;
    aspect-ratio: 16 / 9;
    background: var(--surface-2);
    border-bottom: 1px solid var(--border);
}

.post-card-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Cover-less posts: quiet picture glyph on the soft surface. */
.post-card-media-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--border-strong);
}

.post-card-media-empty svg {
    width: 34px;
    height: 34px;
}

.post-card-body {
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 15px 16px 17px;
    flex: 1;
}

/* Date + category micro-label row (the category takes its tone color). */
.post-card-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    min-width: 0;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.post-card-meta .cat-label {
    min-width: 0;
}

/* Related-app pill (only shown when the category doesn't already name it). */
.post-card-app {
    display: inline-flex;
    align-items: center;
    padding: 2px 9px;
    color: var(--accent);
    background: var(--accent-soft);
    border-radius: 999px;
    white-space: nowrap;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.post-card-title {
    font-size: 16px;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 140ms ease;
}

.post-card-summary {
    font-size: 13px;
    line-height: 1.55;
    color: var(--text-muted);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Guide article page -------------------------------------------------------- */

.post-article {
    max-width: 760px;
}

.post-header h1 {
    font-size: 28px;
    letter-spacing: -0.02em;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin: 10px 0 20px;
    font-size: 13px;
    color: var(--text-muted);
}

.post-cover {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface-2);
    margin-bottom: 22px;
}

/* Related-app callout right under the post header. Mirrors the card
   anatomy used across the site: eyebrow label, icon + titles row, the
   signature-feature line, then the download action on its own line. */
.app-callout {
    padding: 16px 18px 18px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    margin-bottom: 22px;
}

.app-callout-label {
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.app-callout-main {
    display: flex;
    align-items: center;
    gap: 13px;
}

.app-callout-icon {
    width: 56px;
    height: 56px;
    flex: none;
    border-radius: 14px;
    object-fit: cover;
    background: var(--surface-2);
}

.app-callout-titles {
    min-width: 0;
}

.app-callout-name {
    font-size: 15.5px;
    font-weight: 650;
    letter-spacing: -0.01em;
}

.app-callout-dev {
    font-size: 12.5px;
    color: var(--text-muted);
    margin-top: 1px;
}

.app-callout .app-card-highlight {
    margin-top: 12px;
}

.app-callout-action {
    margin-top: 14px;
}

/* "More guides" list below the article. */
.more-guides {
    list-style: none;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
}

.more-guides li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    padding: 11px 18px;
}

.more-guides li + li {
    border-top: 1px solid var(--border);
}

.more-guides a {
    font-weight: 550;
    min-width: 0;
    transition: color 140ms ease;
}

.more-guides a:hover {
    color: var(--accent);
}

.more-guides time {
    flex: none;
    font-size: 12px;
    color: var(--text-muted);
}

/* Responsive ---------------------------------------------------------------- */

@media (max-width: 560px) {
    .post-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .post-header h1 {
        font-size: 23px;
    }
}
