.hmss-v4-story-nav {
    margin: 44px 0 24px;
    padding: 28px;
    border: 1px solid #dce7f3;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(15, 35, 65, .06);
}
.hmss-v4-story-nav__eyebrow,
.hmss-v4-card__label {
    display: inline-block;
    color: #2f6fff;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.hmss-v4-story-nav__title {
    margin: 8px 0 4px;
    color: #132743;
    font-size: clamp(22px, 3vw, 30px);
    line-height: 1.25;
}
.hmss-v4-story-nav__count {
    margin: 0;
    color: #667085;
}
.hmss-v4-story-nav__parts {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin: 24px 0;
}
.hmss-v4-story-nav__part {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 10px;
    border: 1px solid #dce7f3;
    border-radius: 10px;
    background: #f8fbff;
    color: #132743 !important;
    font-weight: 800;
    text-decoration: none !important;
}
.hmss-v4-story-nav__part:hover,
.hmss-v4-story-nav__part:focus-visible {
    border-color: #2f6fff;
    outline: none;
}
.hmss-v4-story-nav__part.is-current {
    border-color: #2f6fff;
    background: #2f6fff;
    color: #fff !important;
}
.hmss-v4-story-nav__pager {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    padding-top: 20px;
    border-top: 1px solid #e7eef6;
}
.hmss-v4-story-nav__pager-side--next { text-align: right; }
.hmss-v4-story-nav__pager-link {
    color: #132743 !important;
    font-weight: 800;
    text-decoration: none !important;
}
.hmss-v4-story-nav__pager-link:hover { color: #2f6fff !important; }

.hmss-v4-parts-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px;
    margin: 32px 0;
}
.hmss-v4-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #dce7f3;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(15, 35, 65, .05);
}
.hmss-v4-card__image { display: block; aspect-ratio: 16/10; overflow: hidden; }
.hmss-v4-card__image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hmss-v4-card__body { display: flex; flex: 1; flex-direction: column; padding: 24px; }
.hmss-v4-card__title { margin: 10px 0 12px; font-size: 22px; line-height: 1.3; }
.hmss-v4-card__title a { color: #132743 !important; text-decoration: none !important; }
.hmss-v4-card__excerpt { color: #667085; line-height: 1.65; }
.hmss-v4-card__button {
    align-self: flex-start;
    margin-top: auto;
    padding: 12px 20px;
    border-radius: 999px;
    background: #ffb51b;
    color: #132743 !important;
    font-weight: 800;
    text-decoration: none !important;
}

/* Best-effort selectors for common HitMag / WordPress post navigation markup. */
.hmss-v4-hide-theme-nav .post-navigation,
.hmss-v4-hide-theme-nav .navigation.post-navigation,
.hmss-v4-hide-theme-nav .single-post-nav,
.hmss-v4-hide-theme-nav .single-post-navigation,
.hmss-v4-hide-theme-nav .post-nav-links:not(.hmss-v4-story-nav__parts) {
    display: none !important;
}

@media (max-width: 980px) {
    .hmss-v4-parts-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
    .hmss-v4-story-nav { padding: 20px; border-radius: 16px; }
    .hmss-v4-story-nav__pager { grid-template-columns: 1fr; }
    .hmss-v4-story-nav__pager-side--next { text-align: left; }
    .hmss-v4-parts-grid { grid-template-columns: 1fr; gap: 20px; }
}
@media (prefers-reduced-motion: no-preference) {
    .hmss-v4-story-nav__part,
    .hmss-v4-card,
    .hmss-v4-card__button { transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
    .hmss-v4-card:hover { transform: translateY(-3px); box-shadow: 0 14px 36px rgba(15,35,65,.09); }
}

/* All Posts Grid / homepage shortcode. Nothing is injected automatically. */
.hmss-v4-home-grid {
    width: 100%;
    max-width: 1180px;
    margin: 36px auto 64px;
    padding: 0 20px;
    box-sizing: border-box;
}
.hmss-v4-home-grid__header {
    margin-bottom: 28px;
    text-align: center;
}
.hmss-v4-home-grid__heading {
    margin: 0;
    text-transform: uppercase;
    color: #132743;
    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.15;
}
.hmss-v4-home-grid__posts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px;
}
.hmss-v4-post-card {
    display: flex;
    min-width: 0;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #dce7f3;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 10px 32px rgba(15, 35, 65, .06);
}
.hmss-v4-post-card__image {
    display: block;
    overflow: hidden;
    aspect-ratio: 16 / 10;
    background: #eef4fa;
}
.hmss-v4-post-card__image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.hmss-v4-post-card__body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 26px 24px 28px;
}
.hmss-v4-post-card__label {
    margin-bottom: 10px;
    color: #2f6fff;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.hmss-v4-post-card__title {
    margin: 0 0 14px;
    color: #132743;
    font-size: 23px;
    line-height: 1.3;
}
.hmss-v4-post-card__title a {
    color: #132743 !important;
    text-decoration: none !important;
}
.hmss-v4-post-card__title a:hover,
.hmss-v4-post-card__title a:focus-visible {
    color: #2f6fff !important;
}
.hmss-v4-post-card__excerpt {
    margin: 0 0 16px;
    color: #667085;
    font-size: 16px;
    line-height: 1.65;
}
.hmss-v4-post-card__date {
    margin: auto 0 18px;
    color: #7b8794;
    font-size: 14px;
}
.hmss-v4-post-card__button {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    min-height: 46px;
    padding: 0 21px;
    border-radius: 999px;
    background: #ffb51b;
    color: #132743 !important;
    font-weight: 800;
    text-decoration: none !important;
}
.hmss-v4-home-grid__actions {
    display: flex;
    justify-content: center;
    margin-top: 34px;
}
.hmss-v4-load-more {
    min-height: 52px;
    padding: 0 30px;
    border: 0;
    border-radius: 999px;
    background: #ffb51b;
    color: #132743;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}
.hmss-v4-load-more:hover { background: #ffa800; }
.hmss-v4-load-more:focus-visible,
.hmss-v4-post-card__button:focus-visible,
.hmss-v4-post-card__title a:focus-visible {
    outline: 3px solid #2f6fff;
    outline-offset: 3px;
}
.hmss-v4-load-more:disabled {
    opacity: .65;
    cursor: wait;
}
.hmss-v4-empty {
    padding: 24px;
    border: 1px dashed #dce7f3;
    border-radius: 16px;
    text-align: center;
}
@media (max-width: 980px) {
    .hmss-v4-home-grid__posts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
    .hmss-v4-home-grid { margin-top: 24px; padding: 0 14px; }
    .hmss-v4-home-grid__posts { grid-template-columns: 1fr; gap: 20px; }
    .hmss-v4-post-card__body { padding: 22px 20px 24px; }
}
@media (prefers-reduced-motion: no-preference) {
    .hmss-v4-post-card,
    .hmss-v4-post-card__image img,
    .hmss-v4-load-more,
    .hmss-v4-post-card__button {
        transition: transform .22s ease, box-shadow .22s ease, background .22s ease;
    }
    .hmss-v4-post-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 16px 40px rgba(15, 35, 65, .10);
    }
    .hmss-v4-post-card:hover .hmss-v4-post-card__image img { transform: scale(1.025); }
    .hmss-v4-is-new { animation: hmssV4CardIn .28s ease both; }
    @keyframes hmssV4CardIn {
        from { opacity: 0; transform: translateY(10px); }
        to { opacity: 1; transform: translateY(0); }
    }
}

/* v4.1 clean static homepage when [all_posts_grid] is used. */
.hmss-v41-clean-home {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 1px 0 36px;
    background: #fff;
}
.hmss-v41-clean-home__page,
.hmss-v41-clean-home__content {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
}
.hmss-v41-clean-home .entry-title,
.hmss-v41-clean-home .page-title,
.hmss-v41-clean-home .entry-header {
    display: none !important;
}
.hmss-v41-clean-home .hmss-v4-home-grid {
    margin-top: 44px;
}


.hmss-v4-post-card__image--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 220px;
    background: linear-gradient(135deg, #eef4fa 0%, #dfeaf5 100%);
    text-decoration: none !important;
}
.hmss-v4-post-card__placeholder-text {
    color: #8091a7;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: .12em;
}
