/* HOMEPAGE DESKTOP */
@media (min-width: 1024px) {
    .homepage-mobile,
    .mobile-post-card {
        display: none !important;
    }
    .homepage-tablet {
        display: none !important;
    }
}

/* HERO GRID */

.homepage-desktop {
    margin-top: 3.5rem;
}

.hero-grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.hero-bg-meta-container {
    background-size: cover;
    background-position: center;
    width: inherit;
    height: inherit;
    display: absolute;
    justify-content: flex-start;
    border-radius: 10px;
    margin-bottom: 0;
    margin-right: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    aspect-ratio: 1.618/1;
    transition: all 0.2s ease 0s;
}

.hero-bg-meta-container:hover {
    border-radius: 24px;
}

.hero-meta-content {
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.5) 0%,
        rgba(0, 0, 0, 0) 100%
    );
    color: var(--text-color-on-picture);
    height: auto;
    border-radius: 8px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1.5rem;
    aspect-ratio: 1.618/1;
    transition: all 0.2s ease 0s;
}

.hero-meta-content:hover {
    border-radius: 24px;
}

.hero-card {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    width: auto;
}

.hero-card a {
    display: block;
    text-decoration: none;
}

.hero-card img {
    width: auto;
    height: 360px;
    object-fit: cover;
    display: block;
    position: center;
}

.hero-card__categories {
    font-size: 1rem;
    margin-top: 0;
    z-index: 2;
}

.hero-card-title {
    margin: 0.3rem 0 0.5rem 0;
}

.hero-card-title a {
    font-size: 1.8rem;
    line-height: 1.2;
    color: var(--text-color-on-picture);
    text-align: center;
}

.hero-card__date {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.8);
}

.hero-card__stretched-link::after {
    content: "";
    position: absolute;
    inset: 0; /* top/right/bottom/left: 0 */
    z-index: 1;
}

/* CONTENT + SIDEBAR */
.content-sidebar-wrap {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 1.5rem;
    align-items: start;
}

.sidebar {
    grid-column: 2;
}

.post-grid {
    display: grid;
    grid-template-columns: 31.5% 31.5% 31.5%;
    gap: 1.5rem;
    align-items: start;
    margin-right: 0;
    min-width: 0;
}

.sidebar-radio h3 {
    margin: 0 0 0.5rem 0;
}

.popular-title,
.wijken-header {
    font-size: 28px !important;
    font-weight: 700;
    width: 100%;
}

.popular-title {
    margin-bottom: 0.5rem;
    margin-top: 0.5rem;
}

.homepage-desktop div aside .popular-title {
    line-height: 1;
    margin:  0;
}

.sidebar-radio h3 {
    font-size: 28px !important;
    font-weight: 700;
}

/* RADIO */
.od-play-btn-front {
    width: 300px;
}

.od-play-btn-front.od-trigger {
    border-radius: 6px;
    height: 55px;
    gap: 8px;
}

.od-play-btn-front.od-trigger:hover {
    border-radius: 27px;
}

.od-play-btn-front svg {
    transition: all 0.2s ease;
    width: 25px;
    height: auto;
    background: var(--od-play-button);
    padding: 10px 10px 10px 12px;
    border-radius: 60px;
}

.od-icon {
    width: 15px;
    height: 15px;
}

.od-play-btn-front.od-trigger:hover svg {
    background: var(--color-accent);
    color: var(--text-color-cats);
}

.od-icon-text {
    font-size: 0.8rem;
    font-weight: 500;
    background: red;
    color: white;
    padding: 4px;
    border-radius: 4px;
}

/* KLEINE KAARTJES */

.post-card-image-wrap {
    position: relative;
    display: block;
    aspect-ratio: 1.618/1;
}

.post-card-image-wrap img {
    width: 100%;
    object-fit: cover;
    border-radius: 4px;
    aspect-ratio: 1.618/1;
}

.post-card-categories {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    position: absolute;
    bottom: 0.5rem;
    left: 0.5rem;
    z-index: 10;
}

.post-card-title {
    margin: 0.3rem 0 0.5rem 0;
}

.post-card-title a {
    color: var(--text-color-comm);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: bold;
}

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

.post-card-date {
    color: var(--text-color-dates);
    font-size: 0.95rem;
    font-weight: 500;
}

/* POPULAR ITEMS */
.popular-item {
    display: grid !important;
    grid-template-columns: 37% minmax(0, 1fr);
    padding: 0.5rem 0;
    text-decoration: none;
    align-items: start;
}

.popular-item-image {
    width: 100%;
    max-width: 160px;
    height: auto;
}

.popular-item-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
    aspect-ratio: 4/3;
    overflow: hidden;
    border-radius: 6px;
    grid-column: 1;
    margin-right: 0.5rem;
    display: block;
}

.popular-item-content {
    padding-left: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: start;
    gap: 0.2rem;
}

.popular-item-title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--text-color-comm);
    transition: color 0.2s ease 0s;
    flex-shrink: 1 !important;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    line-clamp: 4;
    overflow: hidden;
}

h4.popular-item-title {
    white-space: normal;
    overflow-wrap: break-word;
    hyphens: auto;
}

.popular-item-title:hover {
    color: var(--color-accent);
}

.popular-item-date {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-color-dates);
}

/* HOMEPAGE INFINITE SCROLL */

.od-infinite-scroll-ad {
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .od-infinite-scroll-ad {
        padding-left: 0.6rem;
        padding-right: 0.6rem;
    }
}

.desktop-grid-with-sidebar {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 0.5rem;
    align-items: start;
    margin-top: 1rem;
}

.desktop-post-grid {
    min-width: 0;
    padding-right: 1rem;
}

.desktop-post-card {
    display: grid;
    grid-template-columns: 23% 1fr;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.desktop-post-card-image-wrap {
    width: 100%;
    height: auto;
    overflow: hidden;
    position: relative;
}

.desktop-post-card-image-wrap img {
    width: 100%;
    height: auto;
    aspect-ratio: 1.618/1;
    object-fit: cover;
    border-radius: 6px;
}

.desktop-post-card-categories {
    position: absolute;
    bottom: 0.5rem;
    left: 0.5rem;
    z-index: 10;
}

.desktop-post-card-categories .badge:first-of-type {
    margin-bottom: 3px;
}

.desktop-post-card-content {
    margin-left: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: start;
    gap: 0.2rem;
}

.desktop-post-card-title {
    margin: 0;
}

.desktop-post-card-title a {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-color-comm);
}

.desktop-post-card-date {
    font-size: 0.95rem;
    color: var(--text-color-dates);
}

.desktop-load-more-wrap {
    grid-column: 1;
    margin-top: 1rem;
}

/* WIJKEN SIDEBAR */
.stad-header-homepage {
    min-height: 20vh !important;
}

.wijken-sidebar-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.infinite-scroll-sidebar {
    width: 100%;
    top: 1rem;
}

.wijken-container {
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    border-radius: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.2s ease 0s;
    margin-bottom: 1rem;
    text-decoration: none;
    padding-inline: 10px;
    text-align: center;
}

.wijken-container img {
    width: 100%;
    height: auto;
    transition: filter 0.2s ease 0s;
}

.wijken-container:hover img {
    filter: brightness(80%);
}

.wijken-container:hover {
    border-radius: 60px;
    min-height: 15vh;
}

.wijken-container:after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: rgba(0, 0, 0, 0.2);
    pointer-events: none;
    transition: 0.2s ease 0.05s;
}

.wijken-container:hover:after {
    background: rgba(0, 0, 0, 0);
}

.wijken-content {
    position: relative;
    z-index: 2;
}

.wijken-title {
    color: var(--text-color-cats);
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
}

.wijken-title h2 {
    box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.sidebar-stad {
    width: 100%;
}

.sidebar-dorp {
    min-height: 11vh;
    width: 100%;
}

.sidebar-wijk {
    min-height: 8vh;
    width: 80%;
}

/* HOMEPAGE TABLET */

@media (max-width: 1024px) {
    .homepage-desktop {
        display: none;
    }
}

/* HOMEPAGE MOBILE */

@media (max-width: 768px) {
    .homepage-desktop {
        display: none;
    }
}

.mobile-post-card {
    padding-right: 0.6rem;
    padding-left: 0.6rem;
    margin-bottom: 1rem;
}

.mobile-post-card-image-wrap {
    position: relative;
}

.mobile-post-card-image-wrap img {
    width: 100%;
    object-fit: cover;
    border-radius: 6px;
    height: 26vh;
    overflow: hidden;
}

.mobile-post-card-categories {
    position: absolute;
    bottom: 0.5rem;
    left: 0.2rem;
    z-index: 10;
}

.mobile-post-card-title {
    margin: 0.5rem 0 0.2rem 0;
}

.mobile-post-card-title a {
    font-size: 1.2rem;
    font-weight: 700;
    color: inherit;
    transition: color 0.2s ease 0s;
}

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

.mobile-post-card-date {
    color: var(--text-color-dates);
    font-size: 0.8rem;
    font-weight: 500;
}

/* STYLES MOBILE LANDSCAPE */
@media (max-width: 768px) and (orientation: landscape) {
    .mobile-post-card {
        display: grid;
        grid-template-columns: 30% 1fr;
        gap: 0.5rem;
    }

    .mobile-post-card-image-wrap {
        width: 100%;
        aspect-ratio: 1.618/1;
    }
    .mobile-post-card-image-wrap img {
        aspect-ratio: 1.618/1;
        width: 100%;
        height: auto;
    }

    .mobile-post-card-title,
    .mobile-post-card-date {
        margin: 0;
    }
}

/* AGENDA TEASER ONDER WIJKEN */
.sidebar-agenda {
    margin: 1.4rem 0 1.5rem;
    padding: 1.05rem;
    border-radius: 22px;
    background: var(--card-background, #fff);
    border: 1px solid rgba(127,127,127,.18);
    box-shadow: 0 7px 22px rgba(0,0,0,.07);
}

.sidebar-agenda-head {
    display: flex;
    gap: .7rem;
    align-items: baseline;
    justify-content: space-between;
}

.sidebar-agenda-head h2 {
    margin: 0;
    font-size: 1.35rem;
    color: var(--text-color, #111);
}

.sidebar-agenda-head a {
    font-size: .82rem;
    font-weight: 700;
    text-decoration: none;
}

.sidebar-agenda-subtitle {
    margin: .25rem 0 .8rem;
    color: var(--text-color-dates, #777);
    font-size: .86rem;
}

.sidebar-agenda-list {
    display: flex;
    flex-direction: column;
}

.sidebar-agenda-item {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: .7rem;
    padding: .7rem 0;
    border-top: 1px solid rgba(127,127,127,.16);
    text-decoration: none;
    color: inherit;
}

.sidebar-agenda-item:first-child {
    border-top: 0;
}

.sidebar-agenda-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    border-radius: 12px;
    background: var(--accent-color, #e94286);
    color: #fff;
    line-height: 1.05;
}

.sidebar-agenda-date strong {
    text-transform: uppercase;
    font-size: .72rem;
}

.sidebar-agenda-date span {
    margin-top: 3px;
    font-size: .84rem;
    font-weight: 800;
}

.sidebar-agenda-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.sidebar-agenda-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: .94rem;
    line-height: 1.22;
}

.sidebar-agenda-meta {
    margin-top: .24rem;
    color: var(--text-color-dates, #777);
    font-size: .76rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-agenda-item:hover .sidebar-agenda-title {
    text-decoration: underline;
}

.sidebar-agenda-button {
    display: block;
    margin-top: .75rem;
    padding: .72rem .9rem;
    border-radius: 999px;
    text-align: center;
    text-decoration: none;
    font-weight: 800;
    background: var(--accent-color, #e94286);
    color: #fff !important;
}
