/* Modern styling on top of style.css: sidebar widgets and homepage */

/* Inter, self-hosted (latin subset, variable weight) */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../fonts/inter-latin.woff2') format('woff2');
}
body, input, button, textarea, select { font-family: 'Inter', Arial, Helvetica, sans-serif; }
body { font-size: 13px; }

#sidebar .stg-match,
#sidebar .block_secundair {
    width: auto;
    margin: 7px 0 20px 20px; /* right edge lines up with the header search and menu */
    background: #fff;
    border: 1px solid #e2e6ea;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .06);
}

/* Match cards (Volgende / Afgelopen Wedstrijd) */
#sidebar .stg-match { border-top: 4px solid #2e8bd0; padding: 16px 18px 18px; }
#sidebar .stg-match--previous { border-top-color: #a80000; }
#sidebar .stg-match__label { font-size: 11px; line-height: 14px; text-transform: uppercase; letter-spacing: .08em; font-weight: bold; color: #2e8bd0; margin: 0 0 10px; }
#sidebar .stg-match--previous .stg-match__label { color: #a80000; }
#sidebar .stg-match__name { display: block; font-size: 15px; line-height: 20px; font-weight: bold; color: #222; text-decoration: none; margin: 0 0 8px; }
#sidebar .stg-match__type { display: inline-block; font-size: 11px; line-height: 16px; padding: 2px 8px; border-radius: 10px; background: #eef4fa; color: #1f6fae; margin: 0 0 12px; }
#sidebar .stg-match__row { font-size: 13px; line-height: 22px; color: #555; }
#sidebar .stg-match__row span { display: inline-block; width: 62px; color: #999; }
#sidebar .stg-match__row a { color: #555; }
#sidebar .stg-match__button { display: inline-block; margin-top: 14px; padding: 7px 14px; border-radius: 4px; background: #2e8bd0; color: #fff; font-size: 12px; font-weight: bold; text-decoration: none; }
#sidebar .stg-match--previous .stg-match__button { background: #a80000; }
#sidebar .stg-match a:hover { opacity: .85; }

/* Other widgets (Pagina's, Foto's, Video's, Sponsoren) */
#sidebar .block_secundair { padding: 16px 18px 18px; }
#sidebar .block_secundair .block_head { margin: 0 0 12px; border-bottom: 0; }
#sidebar .block_secundair .block_head h3,
#sidebar .block_secundair .block_head h3 a { margin: 0; font-size: 11px; line-height: 14px; text-transform: uppercase; letter-spacing: .08em; font-weight: bold; color: #a80000; }
#sidebar .block_secundair .block_content ul { margin-top: 0; }
#sidebar .block_secundair .block_content .page_list li { list-style: none; margin: 0; line-height: 24px; font-size: 13px; }
#sidebar .block_secundair .block_content .page_list li a { color: #0073c7; text-decoration: none; }
#sidebar .block_secundair .block_content .page_list li a:hover { color: #a80000; }
#sidebar .block_secundair .block_content .page_list li a:before { content: "\203A"; color: #a80000; font-weight: bold; margin-right: 8px; }
#sidebar .block_secundair .block_content .fotos { margin: 0; overflow: hidden; }
#sidebar .block_secundair .block_content .fotos a { background: none; width: auto; height: auto; padding: 0; margin: 0; float: none; }
#sidebar .block_secundair .block_content .fotos img { display: block; border-radius: 4px; }
#sidebar .block_secundair .block_content .meer { float: none; clear: both; margin: 12px 0 0; font-size: 13px; }
#sidebar .block_secundair .block_content .meer a { text-decoration: none; }
#sidebar .block_secundair .block_content img { max-width: 100%; height: auto; }

/* Photo thumbnails as a 3-column grid */
#sidebar .block_secundair .block_content .fotos { font-size: 0; line-height: 0; }
#sidebar .block_secundair .block_content .fotos .ngg-widget { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
#sidebar .block_secundair .block_content .fotos .ngg-widget img { width: 100%; height: auto; }

/* Sponsor logos (transparent versions, *-clean.png), directly on the grey sidebar without a card */
#sidebar .block_secundair.block_sponsors { background: none; border: 0; box-shadow: none; }
#sidebar .block_secundair.block_sponsors .block_head { margin-bottom: 22px; }
#sidebar .block_secundair.block_sponsors .block_content a { display: block; margin: 0 0 18px; }
#sidebar .block_secundair.block_sponsors .block_content a:last-of-type { margin-bottom: 0; }
#sidebar .block_secundair.block_sponsors .block_content img { display: block; margin: 0 auto; width: auto; height: auto; max-width: 190px; max-height: 56px; }
#sidebar .block_secundair.block_sponsors .block_content br { display: none; }

/* Equal-height columns, so the grey page background (.bodybg) no longer shows below the shorter column */
#main .content { display: flex; }
#main .content .col_left { min-height: 0; }

/* Homepage slider */
#main .content .col_left .slider { background: none; width: 640px; height: 275px; margin: 20px 0 0 5px; border-radius: 6px; overflow: hidden; box-shadow: 0 2px 10px rgba(0, 0, 0, .12); }
#main .content .col_left .slider img { margin: 0; display: block; }

/* Homepage news list */
#main .content .col_left .news { padding: 0 25px 0 20px; } /* same left edge as page titles and text */
#main .content .col_left .news .news_head { border-bottom: 1px solid #e2e6ea; margin-top: 28px; padding-bottom: 2px; }
#main .content .col_left .news .news_head .news_archive { font-weight: normal; font-size: 13px; }
#main .content .col_left .news .news_head .news_archive a { color: #0073c7; text-decoration: none; }
#main .content .col_left .news .news_item { border-bottom: 1px solid #eef0f2; padding: 22px 0; overflow: hidden; }
#main .content .col_left .news .news_item .news_img { background: none; width: 100px; height: 100px; padding: 0; margin: 2px 20px 0 0; border-radius: 6px; overflow: hidden; box-shadow: 0 1px 4px rgba(0, 0, 0, .15); }
#main .content .col_left .news .news_item .news_img img { display: block; width: 100px; height: 100px; }
#main .content .col_left .news .news_item h4 { font-size: 17px; line-height: 22px; margin: 0 0 2px; }
#main .content .col_left .news .news_item h4 a { color: #222; text-decoration: none; }
#main .content .col_left .news .news_item h4 a:hover { color: #a80000; }
#main .content .col_left .news .news_item .date { font-size: 12px; color: #999; margin: 0 0 8px; }
#main .content .col_left .news .news_item .news_content { float: none; width: auto; margin: 0 0 0 120px; font-size: 13px; line-height: 20px; color: #555; }
#main .content .col_left .news .news_item .leesmeer { clear: none; text-align: left; margin: 8px 0 0 120px; font-size: 13px; font-weight: normal; }
#main .content .col_left .news .news_item .leesmeer a { color: #0073c7; text-decoration: none; }
#main .content .col_left .news .news_item .leesmeer a:after { content: " \203A"; }

/* Header search */
#header .content .right .search { width: 229px; height: 36px; border: 1px solid #d5dbe1; border-radius: 18px; overflow: hidden; background: #fff; transition: border-color .2s; }
#header .content .right .search:focus-within { border-color: #2e8bd0; }
#header .content .right .zoekopdracht { width: 175px; height: 36px; padding: 0 0 0 16px; background: transparent; color: #333; font-size: 13px; }
#header .content .right .zoekopdracht::placeholder { color: #aaa; }
#header .content .right .zoek_submit { display: flex; align-items: center; justify-content: center; float: left; width: 36px; height: 36px; margin: 0; padding: 0; border: 0; background: none; color: #2e8bd0; line-height: 0; }
#header .content .right .zoek_submit svg { display: block; }
#header .content .right .zoek_submit:hover { color: #a80000; }

/* Main menu */
#header .content .right .navigation ul li { margin: 36px 0 0 20px; font-size: 14px; }
#header .content .right .navigation ul li a { display: inline-block; padding-bottom: 3px; border-bottom: 2px solid transparent; transition: color .2s, border-color .2s; }
#header .content .right .navigation ul li a:hover { border-bottom-color: #a80000; }
#header .content .right .navigation ul li.active a { border-bottom-color: #a80000; }

/* Footer */
#footer { height: auto; padding: 36px 0 0; background: #2f8ccf; }
#footer .footer_top { display: flex; justify-content: space-between; align-items: center; padding-bottom: 28px; }
#footer .footer_brand strong { display: block; font-size: 16px; line-height: 20px; }
#footer .footer_brand span { font-size: 12px; opacity: .8; }
#footer .navigation ul { display: flex; gap: 20px; margin: 0; }
#footer .navigation ul li { list-style: none; font-size: 13px; white-space: nowrap; }
#footer .footer_bottom { display: flex; justify-content: space-between; padding: 16px 0 20px; border-top: 1px solid rgba(255, 255, 255, .25); font-size: 12px; opacity: .85; }
#footer .footer_links a { margin-left: 18px; }
#footer .content a { color: #fff; text-decoration: none; }
#footer .content a:hover { text-decoration: underline; }

/* Page title (all inner pages) */
#main .content .col_left .page_head { width: auto; height: auto; margin: 28px 25px 0 20px; padding: 0 0 14px; background: none; border-bottom: 1px solid #e2e6ea; }
#main .content .col_left .page_head h2 { float: none; margin: 0; line-height: 32px; font-size: 26px; font-weight: 700; color: #222; }
#main .content .col_left .page_head .post_date { float: none; margin: 4px 0 0; line-height: 18px; font-size: 13px; color: #999; }

/* Page text */
#main .content .col_left .page_content { margin: 20px 25px 0 20px; font-size: 14px; line-height: 23px; color: #333; }
#main .content .col_left .page_content p { font-weight: 400; }
#main .content .col_left .page_content h3,
#main .content .col_left .page_content h4 { font-weight: 700; color: #222; margin: 24px 0 8px; }
#main .content .col_left .page_content a { color: #0073c7; }
#main .content .col_left .page_content img { border-radius: 6px; max-width: 100%; height: auto; }
#main .content .col_left .page_content .back-link { margin: 30px 0 0; padding-top: 16px; border-top: 1px solid #eef0f2; font-size: 13px; }
#main .content .col_left .page_content .back-link a { text-decoration: none; }

/* Tables on pages (match calendars and older match lists) */
#main .content .col_left .page_content table { width: 100% !important; border-collapse: collapse; margin: 16px 0 28px; font-size: 13px; }
#main .content .col_left .page_content td { border: 0; border-bottom: 1px solid #eef0f2; padding: 9px 8px; line-height: 18px; vertical-align: top; }
#main .content .col_left .page_content tr:first-child td { background: #f5f7f9; border-bottom: 1px solid #e2e6ea; color: #555; }
#main .content .col_left .page_content tr:first-child td strong { font-weight: 600; }
#main .content .col_left .page_content tr:hover td { background: #fafbfc; }
#main .content .col_left .page_content tr:first-child:hover td { background: #f5f7f9; }
#main .content .col_left .page_content td a { text-decoration: none; }
.stg-calendar td:first-child, .stg-calendar td:first-child + td { white-space: nowrap; }
.stg-calendar td:last-child { text-align: right; }
#main .content .col_left .page_content .stg-btn { display: inline-block; padding: 4px 10px; border-radius: 4px; background: #2e8bd0; color: #fff; font-size: 12px; font-weight: 600; line-height: 16px; white-space: nowrap; }
#main .content .col_left .page_content .stg-btn--results { background: #fff; color: #a80000; border: 1px solid #e6b3b3; }
.stg-tag { display: inline-block; margin-left: 4px; padding: 1px 7px; border-radius: 9px; background: #eef4fa; color: #1f6fae; font-size: 11px; line-height: 15px; }

/* Breadcrumb and current page in the sidebar (sub pages) */
#main .content .col_left .page_head .breadcrumb { margin: 0 0 4px; font-size: 13px; color: #999; }
#main .content .col_left .page_head .breadcrumb a { color: #0073c7; text-decoration: none; }
#sidebar .block_secundair .block_content .page_list li.current_page_item > a { color: #a80000; font-weight: 600; }

/* Photo albums and galleries (NextGEN) */
#main .content .col_left .ngg-albumoverview,
#main .content .col_left .ngg-galleryoverview { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 20px; margin: 10px 0 30px; }
#main .content .col_left .ngg-galleryoverview { grid-template-columns: repeat(auto-fill, minmax(100px, 120px)); gap: 12px; }
/* Editor markup sometimes wraps the thumbnails (e.g. in <strong> or <p>); let those wrappers join the grid */
#main .content .col_left .ngg-galleryoverview > strong,
#main .content .col_left .ngg-galleryoverview > b,
#main .content .col_left .ngg-galleryoverview > p,
#main .content .col_left .ngg-galleryoverview > span { display: contents; }
#main .content .col_left .ngg-album-compact { float: none; width: auto; }
#main .content .col_left .ngg-album-compact h4 { margin: 8px 0 0; font-size: 13px; font-weight: 600; text-align: left; }
#main .content .col_left .ngg-album-compact h4 a { color: #222; text-decoration: none; }
#main .content .col_left .ngg-gallery-thumbnail-box,
#main .content .col_left .ngg-gallery-thumbnail { float: none; width: auto; margin: 0; }
/* Thumbnail links (gallery thumbnails in posts and NextGEN) without the old frame image */
#main .content .col_left .fancybox,
#main .content .col_left .fancybox-youtube,
#main .content .col_left .Link { width: 100px; height: 100px; padding: 0; margin: 6px; background: none; border-radius: 6px; overflow: hidden; box-shadow: 0 1px 4px rgba(0, 0, 0, .15); transition: transform .2s, box-shadow .2s; }
#main .content .col_left .fancybox:hover,
#main .content .col_left .fancybox-youtube:hover,
#main .content .col_left .Link:hover { transform: translateY(-2px); box-shadow: 0 4px 10px rgba(0, 0, 0, .18); }
#main .content .col_left .fancybox img,
#main .content .col_left .fancybox-youtube img,
#main .content .col_left .Link img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 0; }
#main .content .col_left .ngg-galleryoverview .fancybox,
#main .content .col_left .ngg-album-compact .Link { display: block; float: none; width: auto; height: auto; margin: 0; aspect-ratio: 1 / 1; }
#main .content .col_left .ngg-clear,
#main .content .col_left .ngg-navigation { grid-column: 1 / -1; }

/* WordPress galleries in posts ([gallery] markup) */
#main .content .col_left .gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 120px)); gap: 12px; margin: 10px 0 24px; }
#main .content .col_left .gallery .gallery-row { display: contents; }
#main .content .col_left .gallery .gallery-item { float: none; width: auto !important; margin: 0; }
#main .content .col_left .gallery .gallery-icon { margin: 0; }
#main .content .col_left .gallery .fancybox { display: block; float: none; width: auto; height: auto; margin: 0; aspect-ratio: 1 / 1; }
#main .content .col_left .gallery br { display: none; }

/* Fluid layout: at most 1100px wide, narrower on smaller screens (never below 940px) */
#header .content, #main .content, #footer .content { width: calc(100% - 40px); max-width: 1100px; min-width: 940px; }
#main .content .col_left { flex: 1 1 auto; width: auto; min-width: 0; }
#main .content .col_right { flex: 0 0 299px; width: 299px; }
#main .content .col_left .slider { width: auto; height: auto; aspect-ratio: 640 / 275; margin: 20px 25px 0 20px; }
#main .content .col_left .slider img { width: 100%; height: 100%; object-fit: cover; }

/* Dropdown with sub pages in the main menu */
#header { position: relative; z-index: 20; }
#header .content .right .navigation ul li { position: relative; }
#header .content .right .navigation ul li.has-children > a:after { content: ""; display: inline-block; width: 5px; height: 5px; margin: 0 0 3px 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); }
#header .content .right .navigation ul li .sub-menu { display: none; position: absolute; top: 100%; left: -14px; z-index: 50; min-width: 200px; margin: 0; padding: 8px 0; background: #fff; border: 1px solid #e2e6ea; border-radius: 6px; box-shadow: 0 8px 20px rgba(0, 0, 0, .12); }
#header .content .right .navigation ul li:hover > .sub-menu,
#header .content .right .navigation ul li:focus-within > .sub-menu { display: block; }
#header .content .right .navigation ul li .sub-menu li { float: none; margin: 0; font-size: 13px; }
#header .content .right .navigation ul li .sub-menu li a,
#header .content .right .navigation ul li.active .sub-menu li a { display: block; padding: 7px 16px; border: 0; color: #0073c7; white-space: nowrap; }
#header .content .right .navigation ul li .sub-menu li a:hover { background: #f5f7f9; color: #a80000; }

/* Search results */
#main .content .col_left .search_results { padding: 0 25px 0 20px; }
#main .content .col_left .search_results .search_item { border-bottom: 1px solid #eef0f2; padding: 20px 0; }
#main .content .col_left .search_results .search_item h4 { font-size: 17px; line-height: 22px; font-weight: 700; margin: 0 0 6px; }
#main .content .col_left .search_results .search_item h4 a { color: #222; text-decoration: none; }
#main .content .col_left .search_results .search_item h4 a:hover { color: #a80000; }
#main .content .col_left .search_results .search_item .search_content { font-size: 13px; line-height: 20px; color: #555; margin: 0; }
#main .content .col_left .search_results .search_item .leesmeer { margin: 8px 0 0; font-size: 13px; font-weight: normal; }
#main .content .col_left .search_results .search_item .leesmeer a { color: #0073c7; text-decoration: none; }
#main .content .col_left .search_results .search_item .leesmeer a:after { content: " \203A"; }

/* Match details (single langebaan/marathon pages): label/value list, not a table with a header row */
#main .content .col_left .page_content .wedstrijd_metadata tr:first-child td,
#main .content .col_left .page_content .wedstrijd_metadata tr:hover td { background: none; border-bottom: 1px solid #eef0f2; }
#main .content .col_left .page_content .wedstrijd_metadata tr td.desc { color: #999; }
#main .content .col_left .page_content .wedstrijd_metadata td.desc { width: 110px; color: #999; }
#main .content .col_left .page_content .wedstrijd_metadata td.desc strong { font-weight: 400; }
