/*
Theme Name: Abundant (Astra Child)
Theme URI: https://abundant.nu
Description: Custom look-and-feel voor Abundant. Warme crème basis, serif headings, ronde hoeken en pill-buttons — geïnspireerd op OuderAtelier.
Author: Abundant
Template: astra
Version: 0.4.0
Text Domain: abundant-child
*/

/* -------- Fonts (lokaal, geen Google: AVG) -------- */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 600;
    font-display: swap;
    src: url('assets/fonts/inter-latin.woff2') format('woff2');
}
@font-face {
    font-family: 'Playfair Display';
    font-style: normal;
    font-weight: 500 600;
    font-display: swap;
    src: url('assets/fonts/playfair-latin.woff2') format('woff2');
}
@font-face {
    font-family: 'Playfair Display';
    font-style: italic;
    font-weight: 500;
    font-display: swap;
    src: url('assets/fonts/playfair-italic-latin.woff2') format('woff2');
}

/* -------- Design tokens -------- */
:root {
    --ab-cream:        #E8CBC0;
    --ab-cream-soft:   #F7F0E5;
    --ab-cream-warm:   #DFB6A8;
    --ab-ink:          #1E1B18;
    --ab-ink-muted:    #4A4741;
    --ab-line:         #D9AFA0;
    --ab-accent:       #1E1B18;
    --ab-accent-hover: #3A342C;
    --ab-terracotta:      #B5582F;
    --ab-terracotta-soft: #C97C52;

    --ab-radius-sm:    8px;
    --ab-radius:       16px;
    --ab-radius-lg:    24px;
    --ab-radius-pill:  999px;

    --ab-font-body:  'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    --ab-font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;

    --ab-shadow-soft: 0 1px 2px rgba(30, 27, 24, 0.04), 0 4px 12px rgba(30, 27, 24, 0.06);
}

/* -------- Base -------- */
html,
body {
    background: var(--ab-cream);
    color: var(--ab-ink);
    font-family: var(--ab-font-body);
    font-size: 17px;
    line-height: 1.65;
}

.site,
.hfeed.site,
#page {
    background: transparent;
}

/* Astra zet de inhoud standaard op wit; wij willen overal crème. */
body.ast-plain-container,
body.ast-separate-container,
body.ast-narrow-container,
body.ast-page-builder-template {
    background-color: var(--ab-cream);
}
.ast-narrow-container .site-content,
.ast-separate-container .ast-article-single:not(.ast-related-post),
.ast-separate-container .ast-article-inner,
.ast-box-layout.ast-plain-container .site-content,
.ast-padded-layout.ast-plain-container .site-content {
    background-color: transparent;
}
body.ast-separate-container .ast-article-single { padding: 0; }

/* -------- Typografie -------- */
h1, h2, h3, h4, h5, h6,
.entry-title,
.site-title,
.wp-block-post-title,
.wp-block-heading {
    font-family: var(--ab-font-serif);
    color: var(--ab-ink);
    font-weight: 500;
    letter-spacing: -0.005em;
    line-height: 1.2;
}

h1, .entry-title { font-size: clamp(2rem, 3.5vw, 3rem); font-weight: 600; }
h2               { font-size: clamp(1.5rem, 2.5vw, 2.1rem); }
h3               { font-size: clamp(1.25rem, 2vw, 1.6rem); }

/* Homepage titel: gecentreerd, met wat lucht en een klein accentstreepje */
.page-id-2 .entry-title {
    text-align: center;
    margin: 2rem 0 1.5rem;
    position: relative;
    padding-bottom: 1rem;
}
.page-id-2 .entry-title::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 48px;
    height: 3px;
    background: var(--ab-terracotta);
    border-radius: var(--ab-radius-pill);
}

em, i, .is-style-italic { font-style: italic; }

p, li { color: var(--ab-ink); }

.has-small-font-size,
.wp-block-post-date,
.entry-meta,
small,
figcaption {
    color: var(--ab-ink-muted);
    font-size: 0.9em;
}

/* -------- Links -------- */
a {
    color: var(--ab-ink);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: color .15s ease;
}
a:hover,
a:focus {
    color: var(--ab-accent-hover);
}

/* -------- Buttons (WP core + Astra + gewone) -------- */
.wp-block-button__link,
.wp-block-button .wp-element-button,
.wp-block-search__button,
.wp-element-button,
button:not(.components-button):not(.wp-block-navigation-submenu__toggle),
input[type="button"],
input[type="submit"],
input[type="reset"],
.ast-button,
.button,
.ast-custom-button,
.menu-toggle {
    background: var(--ab-accent);
    color: #fff !important;
    border: none;
    border-radius: var(--ab-radius-pill);
    padding: 0.7em 1.6em;
    font-family: var(--ab-font-body);
    font-weight: 500;
    font-size: 0.95rem;
    text-decoration: none;
    line-height: 1.2;
    box-shadow: var(--ab-shadow-soft);
    transition: background .2s ease, transform .1s ease;
    cursor: pointer;
}

.wp-block-button__link:hover,
.wp-block-button .wp-element-button:hover,
.wp-element-button:hover,
button:not(.components-button):hover,
input[type="submit"]:hover,
.ast-button:hover,
.button:hover {
    background: var(--ab-accent-hover);
    color: #fff !important;
    transform: translateY(-1px);
}

/* Outline button variant (overschrijft Astra's global-color outline styles) */
.is-style-outline .wp-block-button__link,
.wp-block-button.is-style-outline .wp-element-button,
div.wp-block-button.is-style-outline > .wp-block-button__link {
    background: transparent !important;
    color: var(--ab-ink) !important;
    border: 1px solid var(--ab-ink) !important;
    border-color: var(--ab-ink) !important;
    box-shadow: none !important;
}
.is-style-outline .wp-block-button__link:hover,
div.wp-block-button.is-style-outline > .wp-block-button__link:hover {
    background: var(--ab-ink) !important;
    color: #fff !important;
    border-color: var(--ab-ink) !important;
}

/* -------- Kaarten / groups met achtergrond -------- */
.wp-block-group.has-background,
.wp-block-column.has-background,
.wp-block-columns.has-background,
.wp-block-cover,
.wp-block-media-text,
.wp-block-quote,
.wp-block-pullquote {
    border-radius: var(--ab-radius);
    overflow: hidden;
}

.wp-block-group.has-background,
.wp-block-column.has-background {
    padding: 1.75rem 2rem;
    box-shadow: var(--ab-shadow-soft);
}

/* Zachte cream card variant (past bij tokens) */
.wp-block-group.is-style-ab-card,
.wp-block-column.is-style-ab-card {
    background: var(--ab-cream-soft);
    border: 1px solid var(--ab-line);
    border-radius: var(--ab-radius-lg);
    padding: 2rem 2.25rem;
    box-shadow: var(--ab-shadow-soft);
}

.is-style-ab-card > .wp-block-heading:first-child {
    border-left: 3px solid var(--ab-terracotta);
    padding-left: 0.75rem;
    margin-top: 0;
    margin-bottom: 1.25rem;
}

/* Astra geeft .wp-block-columns standaard wat extra zijmarge; deze kaart
   moet daar exact mee uitlijnen ook al is het geen columns-blok. */
.entry-content > .ab-header-card {
    margin-left: var(--wp--custom--ast-default-block-left-padding, 0px) !important;
    margin-right: var(--wp--custom--ast-default-block-right-padding, 0px) !important;
}

/* Astra's default blok-padding maakt de verticale ruimte tussen secties
   onvoorspelbaar groot; we sturen het ritme liever zelf via margins. */
.entry-content > .wp-block-columns {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

/* Laat deze kaart even breed uitbreken uit de smalle leeskolom als Astra's
   hero-afbeelding erboven doet (zelfde -120px truc, zelfde breakpoint: 922px). */
@media (min-width: 922px) {
    .entry-content > .ab-photo-match-card {
        margin-left: -120px !important;
        margin-right: -120px !important;
        max-width: unset !important;
        width: unset !important;
    }
}

.ab-subheading {
    color: var(--ab-terracotta);
    font-family: var(--ab-font-serif);
    font-weight: 600;
    font-size: 1.05rem;
    margin: 1.5rem 0 0.25rem;
}
.is-style-ab-card .wp-block-heading:first-child + .ab-subheading {
    margin-top: 0;
}
.ab-note {
    color: var(--ab-terracotta-soft);
    font-style: italic;
    font-size: 0.9em;
}
.ab-subtitle {
    font-family: var(--ab-font-serif);
    font-style: italic;
    font-weight: 600;
    font-size: 1.3rem;
    color: var(--ab-terracotta);
}
.ab-quote-text {
    font-family: var(--ab-font-serif);
    font-style: italic;
    font-size: 1.15rem;
}

/* -------- Afbeeldingen -------- */
.wp-block-image img,
.wp-block-post-featured-image img,
.wp-block-cover__image-background,
.wp-block-media-text__media img,
.wp-post-image,
.attachment-post-thumbnail,
.post-thumbnail img,
.entry-content img {
    border-radius: var(--ab-radius);
}

.wp-block-image.is-style-rounded img,
img.is-style-rounded {
    border-radius: var(--ab-radius-pill);
}

/* -------- Formulieren -------- */
input[type="text"],
input[type="email"],
input[type="url"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
    background: var(--ab-cream-soft);
    color: var(--ab-ink);
    border: 1px solid var(--ab-line);
    border-radius: var(--ab-radius-sm);
    padding: 0.65rem 0.9rem;
    font-family: var(--ab-font-body);
    font-size: 1rem;
    transition: border-color .15s ease, box-shadow .15s ease;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--ab-ink);
    box-shadow: 0 0 0 3px rgba(30,27,24,0.08);
}

/* -------- Header / footer -------- */
.site-header,
.ast-primary-header-bar,
.main-header-bar,
.ast-above-header,
.ast-below-header {
    background: var(--ab-cream) !important;
    border-bottom: 1px solid var(--ab-line);
    box-shadow: none;
}

/* Logo badge — houdt afmeting consistent, ronde vorm ook als het geen cirkel is */
.site-branding,
.ast-site-identity {
    padding: 0.5rem 0;
}

.custom-logo-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border-radius: var(--ab-radius-pill);
    overflow: hidden;
    background: transparent;
    transition: transform .2s ease;
}

.custom-logo-link:hover { transform: scale(1.03); }

.custom-logo-link img.custom-logo {
    width: 72px;
    height: 72px;
    max-height: 72px;
    object-fit: contain;
    border-radius: var(--ab-radius-pill);
    display: block;
    filter: none !important;
}

/* Site titel naast het logo als er geen tagline is */
.site-title,
.ast-site-title {
    font-family: var(--ab-font-serif);
    font-weight: 600;
    letter-spacing: -0.005em;
}
.site-title a { text-decoration: none; }

.site-description,
.ast-site-description {
    font-family: var(--ab-font-serif);
    font-style: italic;
    color: var(--ab-terracotta);
    font-size: 0.95rem;
}

.site-footer,
.site-footer .site-primary-footer-wrap,
.site-footer .site-below-footer-wrap,
.ast-small-footer {
    background: var(--ab-cream-warm) !important;
    color: var(--ab-ink);
    border-top: 1px solid var(--ab-line);
}
.site-footer .footer-widget-area {
    background: transparent !important;
}
.site-footer a { color: var(--ab-ink); }

/* -------- Menu -------- */
.main-header-menu > li > a,
.main-navigation a {
    font-family: var(--ab-font-body);
    font-weight: 500;
    text-decoration: none;
    color: var(--ab-ink);
}
.main-header-menu > li > a:hover {
    color: var(--ab-accent-hover);
}
.main-header-menu > .current-menu-item > a,
.main-header-menu > .current-menu-item > a:hover {
    color: var(--ab-terracotta) !important;
}

/* -------- Scheidingslijnen -------- */
hr,
.wp-block-separator {
    border: none;
    border-top: 1px solid var(--ab-line);
    margin: 2rem 0;
}

/* -------- Blockquote -------- */
blockquote,
.wp-block-quote {
    border-left: 3px solid var(--ab-ink);
    padding: 0.5rem 0 0.5rem 1.25rem;
    background: transparent;
    font-family: var(--ab-font-serif);
    font-style: italic;
    color: var(--ab-ink);
}

/* -------- Responsief -------- */
@media (max-width: 600px) {
    html, body { font-size: 16px; }

    .wp-block-group.is-style-ab-card,
    .wp-block-column.is-style-ab-card {
        padding: 1.5rem 1.25rem;
        border-radius: var(--ab-radius);
    }

    .ab-subtitle { font-size: 1.1rem; }
    .ab-quote-text { font-size: 1rem; }

    .wp-block-buttons {
        flex-direction: column;
        align-items: stretch;
    }
    .wp-block-buttons .wp-block-button__link {
        text-align: center;
    }
}

img,
.wp-block-image img,
.wp-post-image {
    max-width: 100%;
    height: auto;
}

/* -------- Gedeelde kaart-knoppen (documenten + agenda) -------- */
.ab-doc__btn,
.ab-event__btn,
.entry-content a.ab-doc__btn,
.entry-content a.ab-event__btn {
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: .35em;
    background: var(--ab-accent);
    color: #fff !important;
    border: 1px solid var(--ab-accent);
    border-radius: var(--ab-radius-pill);
    padding: .5em 1.2em;
    font-family: var(--ab-font-body);
    font-weight: 500;
    font-size: .9rem;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
    transition: background .2s ease, transform .1s ease;
}
.ab-doc__btn:hover,
.ab-event__btn:hover {
    background: var(--ab-accent-hover);
    color: #fff !important;
    transform: translateY(-1px);
}
.ab-event__btn--outline,
.entry-content a.ab-event__btn--outline {
    background: transparent;
    color: var(--ab-ink) !important;
    border-color: var(--ab-ink);
}
.ab-event__btn--outline:hover,
.entry-content a.ab-event__btn--outline:hover {
    background: var(--ab-ink);
}

/* -------- Documenten -------- */
.ab-docs__year + .ab-docs__year { margin-top: 2rem; }
.ab-docs__year-title {
    border-left: 3px solid var(--ab-terracotta);
    padding-left: .75rem;
    margin: 0 0 1rem;
}
.ab-docs__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: .75rem;
}
.ab-doc {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--ab-cream-soft);
    border: 1px solid var(--ab-line);
    border-radius: var(--ab-radius);
    padding: .9rem 1.1rem;
    box-shadow: var(--ab-shadow-soft);
}
.ab-doc__icon {
    flex: none;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: var(--ab-radius-sm);
    background: var(--ab-cream);
    color: var(--ab-terracotta);
}
.ab-doc__body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ab-doc__title { font-weight: 600; line-height: 1.3; }
.ab-doc__meta { color: var(--ab-ink-muted); font-size: .85rem; }

/* -------- Agenda -------- */
/* Sectiekopjes in de agenda: klein label met lijn, zodat de paginatitel
   en de titels op de kaartjes de hiërarchie dragen. */
.entry-content .ab-agenda__heading {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 3rem 0 1.25rem;
    font-family: var(--ab-font-body);
    font-size: .8rem;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--ab-terracotta);
}
.entry-content .ab-agenda__heading::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--ab-line);
}
.entry-content .ab-agenda__heading:first-child { margin-top: .5rem; }
.ab-agenda__list { display: grid; gap: 1.25rem; }
.entry-content .ab-agenda { margin-bottom: 1.5rem; }
.entry-content .wp-block-heading + .ab-agenda,
.entry-content .ab-agenda { margin-top: 1rem; }
.entry-content > .is-style-ab-card + .wp-block-heading { margin-top: 3rem; }
.ab-agenda__empty { color: var(--ab-ink-muted); font-style: italic; }

.ab-event {
    display: grid;
    grid-template-columns: minmax(0, 38%) minmax(0, 1fr);
    background: var(--ab-cream-soft);
    border: 1px solid var(--ab-line);
    border-radius: var(--ab-radius-lg);
    overflow: hidden;
    box-shadow: var(--ab-shadow-soft);
}
.ab-event--plain { grid-template-columns: minmax(0, 1fr); border-left: 4px solid var(--ab-terracotta); }

.ab-event__media { position: relative; min-height: 180px; background: var(--ab-cream); }
.ab-event__media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100% !important;
    object-fit: cover;
    border-radius: 0 !important;
}
.ab-event__media--date { display: grid; place-items: center; }

.ab-date {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    min-width: 84px;
    padding: .6rem .8rem;
    background: var(--ab-cream-soft);
    border-radius: var(--ab-radius);
    box-shadow: var(--ab-shadow-soft);
    text-align: center;
    line-height: 1.1;
}
.ab-event__media .ab-date { position: absolute; top: .9rem; left: .9rem; }
.ab-event__media--date .ab-date { position: static; }
.ab-date__month {
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: .75rem;
    font-weight: 600;
    color: var(--ab-terracotta);
}
.ab-date__day {
    font-family: var(--ab-font-serif);
    font-size: 1.9rem;
    font-weight: 600;
    white-space: nowrap;
}
.ab-date__year { font-size: .75rem; color: var(--ab-ink-muted); }

.ab-event__body { padding: 1.4rem 1.6rem; }
.ab-event__when {
    margin: 0 0 .25rem;
    color: var(--ab-terracotta);
    font-family: var(--ab-font-serif);
    font-style: italic;
    font-weight: 500;
}
.entry-content .ab-event__title { margin: 0 0 .35rem; }
.entry-content .ab-event__title a { text-decoration: none; }
.ab-event__title a:hover { text-decoration: underline; }
.ab-event__location { margin: 0 0 .5rem; color: var(--ab-ink-muted); font-size: .9rem; }
.ab-event__excerpt { margin: 0 0 1rem; }
.ab-event__actions { display: flex; flex-wrap: wrap; gap: .6rem; margin: 0; }

.ab-event-image { margin: 0 0 1.5rem; }
.ab-event-image img { width: 100%; max-height: 420px; object-fit: cover; }

/* Losse activiteit: Wanneer/Waar-blok */
.ab-event-info {
    background: var(--ab-cream-soft);
    border: 1px solid var(--ab-line);
    border-left: 4px solid var(--ab-terracotta);
    border-radius: var(--ab-radius);
    padding: 1.1rem 1.4rem;
    margin: 0 0 2rem;
}
.ab-event-info dl { margin: 0; display: grid; gap: .4rem; }
.ab-event-info dl > div { display: grid; grid-template-columns: 6.5rem 1fr; gap: 1rem; }
.ab-event-info dt { font-weight: 600; }
.ab-event-info dd { margin: 0; }
.ab-event-info__actions { margin: 1rem 0 0; }
.ab-event-info__back { margin-top: 2.5rem; }

/* -------- Footer -------- */
.site-footer .site-primary-footer-wrap { padding: 2.5rem 0 1.5rem; }
.site-footer .site-below-footer-wrap { border-top: 1px solid var(--ab-line); }
.site-footer .footer-widget-area,
.site-footer .ast-footer-html-inner,
.site-footer .footer-widget-area[data-section="section-fb-html-1"] { text-align: left; }
.site-footer #astra-footer-menu { justify-content: flex-end; }
@media (max-width: 921px) {
    .site-footer #astra-footer-menu { justify-content: flex-start; }
}
.site-footer { font-size: .9rem; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer .ast-builder-grid-row { align-items: start; }
.site-footer .footer-widget-area .menu,
.site-footer .ast-nav-menu {
    font-family: var(--ab-font-body);
}
.site-footer .ab-footer-org,
.site-footer .ab-footer-org p { text-align: left; }
.ab-footer-org strong {
    font-family: var(--ab-font-serif);
    font-weight: 600;
    font-size: 1.05rem;
}
.ab-footer-org p { margin: 0 0 .35rem; color: var(--ab-ink); }

@media (max-width: 600px) {
    .ab-event { grid-template-columns: minmax(0, 1fr); }
    .site-footer .site-primary-footer-wrap,
    .site-footer .site-below-footer-wrap { padding-left: 16px; padding-right: 16px; }
    .site-footer #astra-footer-menu { flex-direction: column; align-items: flex-start; }
    .site-footer #astra-footer-menu .menu-item,
    .site-footer #astra-footer-menu .menu-link { text-align: left; justify-content: flex-start; padding-left: 0; }
    .site-footer .footer-widget-area[data-section="section-fb-nav-menu"] { margin-top: 1rem; }
    .ab-event__media { min-height: 0; aspect-ratio: 16 / 9; }
    .ab-event__media--date { aspect-ratio: auto; padding: 1rem 0 0; background: transparent; justify-items: start; padding-left: 1.6rem; }
    .ab-event__body { padding: 1.1rem 1.25rem 1.3rem; }
    .ab-doc { flex-wrap: wrap; }
    .ab-doc__btn { margin-left: 60px; }
    .ab-event-info dl > div { grid-template-columns: 1fr; gap: 0; }
}

/* -------- Selectie -------- */
::selection { background: var(--ab-ink); color: var(--ab-cream); }
