/* INITIAL SEARCH PAGE LAYOUT */

ul.event-grid {
        margin-top: 0.5em;
}
    /* =============================================
       RESET & BASE
       ============================================= */
    *, *::before, *::after {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    /* =============================================
       GRID LAYOUT
       1 col  → mobile (default)
       2 cols → ≥ 600px
       3 cols → ≥ 900px
       4 cols → ≥ 1200px
       ============================================= */
    .event-grid {
      display: grid;
      grid-template-columns: 1fr;
      gap: 1.5rem;
      max-width: 1400px;
      margin: 0 auto;
      list-style: none; /* <ul> used for semantics */
      padding: 0;
    }
    
    .event-results {
            margin-top: 1em;
    }

    @media (min-width: 600px) {
      .event-grid {
        grid-template-columns: repeat(2, 1fr);
      }
    }

    @media (min-width: 900px) {
      .event-grid {
        grid-template-columns: repeat(3, 1fr);
      }
    }

    @media (min-width: 1200px) {
      .event-grid {
        grid-template-columns: repeat(4, 1fr);
      }
    }
    
    .event-grid > li {
        min-width: 0; /* stops content dictating cell width */
        display: flex;
    }
    
    /* =============================================
       CARD
       ============================================= */
    .event-card {
      width: 100%;
      min-width: 0%;
      background: #ffffff;
      border: 1px solid #d0d0d0;
      border-radius: 12px;
      display: flex;
      flex-direction: column;
      overflow: hidden;
      /* Lift on hover — purely decorative, no info loss */
      transition: box-shadow 0.2s ease;
      font-size: 0.9rem !important;
    }

    .event-card .greybg {
        background: #f1f1f1;
        padding: 1rem 1.125rem;
        font-size: 0.9rem !important;
    }
    .event-card .greybg a:hover {
        color: #000;
    }
    .event-card:hover {
      box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }

    /* =============================================
       CARD IMAGE AREA
       Background colour is the category accent.
       The <img> is decorative so alt="" is correct
       when it truly adds no information. Replace
       alt="" with a description if the image is
       meaningful.
       ============================================= */
    .event-card__image-wrap {
        position: relative;
        height: 15px;
        /* padding: 0 15px; */
        overflow: hidden;
        display: flex;
        background-color: #e6e6e6;
        align-items: center;
        justify-content: center;
        border-radius: 12px 12px 0px 0px;
        /* border: 0.5px solid red; */
        width: 100%;
        margin: 0 auto;
    }

    .event-card__image-wrap img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      display: block;
    }

    /* Placeholder icon shown when no image is provided */
    .event-card__image-wrap .placeholder-icon {
      font-size: 3rem;
      color: rgba(255, 255, 255, 0.7);
      pointer-events: none;
      aria-hidden: true;
    }

    /* Category-based image accent colours 
    .event-card--arts    .event-card__image-wrap { background-color: #3daaa8; }
    .event-card--health  .event-card__image-wrap { background-color: #c8e8f0; }
    .event-card--social  .event-card__image-wrap { background-color: #b8aad4; }
    .event-card--fitness .event-card__image-wrap { background-color: #d4eaf5; }
*/
    /* =============================================
       CARD BODY
       Uses flex-grow so "Read more" link always
       sits at the bottom regardless of content
       height across sibling cards.
       ============================================= */
    .event-card__body {
      padding: 1rem 1.125rem;
      display: flex;
      flex-direction: column;
      flex: 1;
      gap: 0.5rem;
    }
    .event-card__body ul {
    list-style: disc;
    margin-left: 1em;
    }

    /* =============================================
       CATEGORY LABEL
       Meets 4.5:1 contrast on white (#767676 is
       the WCAG AA border for small text on white).
       Using #595959 here gives ~7:1.
       ============================================= */
    .event-card__category, .event-card__region {
      font-size: 0.8125rem;  /* 13px */
      font-weight: 400;
      color: #595959;
      text-transform: none;
      letter-spacing: 0;
    }

    /* =============================================
       TITLE
       Rendered as <h3> inside a <ul>/<li> —
       heading level should match your page outline.
       Change to h2/h3 as appropriate.
       ============================================= */
    .event-card__title {
      font-size: 1.3rem;   /* 18px */
      font-weight: 700;
      line-height: 1.3;
      color: #1a1a1a;
      /* No extra margin needed — gap handles spacing */
    }
    .subtitle {
    font-weight: bold !important;
    font-size: 0.9rem !important;
    }
    /* =============================================
       DESCRIPTION
       ============================================= */
    .event-card__description {
      font-size: 0.9375rem;  /* 15px */
      color: #333333;
      line-height: 1.5;
      flex: 0; /* Push date + link to bottom */
    }

    /* =============================================
       PROGRAMME TAG  (e.g. *Waterway Tales)
       Colour meets 4.5:1 on white — #b5000a is ~5.2:1
       ============================================= */
    .event-card__programme {
      font-size: 0.875rem;
      font-weight: 600;
      color: #333;
    }

    /* .event-card__programme::before {
      content: "* ";
    } */

    /* =============================================
       DATE
       ============================================= */
    .event-card__date {
      font-size: 0.875rem;
      color: #333333;
      margin-top: 0.25rem;
    }

    /* =============================================
       READ MORE LINK
       - Underline always visible (WCAG 2.4.4 / SC 1.4.1)
       - Focus indicator: 3px solid offset outline
         meets WCAG 2.2 SC 2.4.11 (focus appearance)
       - The visually hidden span gives screen readers
         the unique link destination.
       ============================================= */
    .event-card__link {
      display: inline-block;
      margin-top: 0.75rem;
      font-size: 0.9375rem;
      font-weight: 600;
      color: #005a8e;       /* ~6.2:1 on white */
      text-decoration: underline;
      text-underline-offset: 3px;
      /* Ensure the entire card isn't the link target —
         only this element is interactive */
    }

    .event-card__link:hover {
      color: #003f63;
      text-decoration-thickness: 2px;
    }

    /* WCAG 2.2 SC 2.4.11 Focus Appearance:
       focus indicator has area ≥ perimeter × 2px
       and ≥ 3:1 contrast against adjacent colours. */
    .event-card__link:focus-visible {
      outline: 3px solid #005a8e;
      outline-offset: 3px;
      border-radius: 2px;
      text-decoration: none;
    }

    /* Visually hidden but available to assistive tech */
    .visually-hidden {
      position: absolute;
      width: 1px;
      height: 1px;
      margin: -1px;
      padding: 0;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      white-space: nowrap;
      border: 0;
    }

    /* =============================================
       REDUCED MOTION
       ============================================= */
    @media (prefers-reduced-motion: reduce) {
      .event-card {
        transition: none;
      }
    }

    /* =============================================
       HIGH CONTRAST MODE (Windows forced colours)
       ============================================= */
    @media (forced-colors: active) {
      .event-card {
        border: 2px solid ButtonText;
      }
      .event-card__link {
        color: LinkText;
      }
      .event-card__programme {
        color: Mark;
      }
    }

    /* =============================================
       SECTION HEADING (optional page context)
       ============================================= */
    .listings-heading {
      font-size: 1.5rem;
      font-weight: 700;
      margin-bottom: 1.5rem;
      color: #1a1a1a;
      max-width: 1400px;
      margin-left: auto;
      margin-right: auto;
    }

    /* =============================================
       RESET FILTERS BUTTON
       ============================================= */

    .event-filter-reset {
        padding: 9px;
        font-size: 18px;
        border-radius: 5px;
        border: none;
        background: #008087;
        color: #fff;
        cursor: pointer;
        font-weight: 600;
    }
    
    /* =============================================
       PAGINATION
       ============================================= */

    .event-pagination {
      display: flex;
      flex-wrap: wrap;
      gap: 0.4rem;
      margin-top: 1.5rem;
      align-items: center;
    }
    
    .event-pagination__btn {
      padding: 0.4rem 0.8rem;
      border: 1px solid #666;
      background: #fff;
      cursor: pointer;
      border-radius: 4px;
      font-size: 0.95rem;
    }
    
    .event-pagination__btn:disabled {
      opacity: 0.4;
      cursor: default;
    }
    
    .event-pagination__page--active {
      background: #333;
      color: #fff;
      border-color: #333;
      font-weight: bold;
    }    
        
/* REULTS PAGE STYLES */

/* SEARCH/FILTER Assets */
/* ====================
   THIS COMPONENT LINKED TO MULTIPLE ASSETS - CHECK PARENT LINKING */

/* add modified, shorter cards for mobile view */

/* Styles - Initial search page */

.event-card__date-short {
    display: none;
}
@media (max-width: 450px) {
    .event-card__date,
    .event-card__description,
    .read-more {
        display: none!important;
    }
    .event-card__date-short {
        display: block!important;
    }
    .event-card__image-wrap {
        height: 5px!important;
    }
}    
    
    
.event-card__image-wrap img {
    display: none!important;
}

/* ------ Card colours category style -------- */

.event-card__image-wrap[class^="event-card__image-wrap one"], #queries_category_query_one {
    background-color: #4db8b8;
}
.event-card__image-wrap[class^="event-card__image-wrap two"] {
    background-color: #f0e4de;
}
.event-card__image-wrap[class^="event-card__image-wrap three"] {
    background-color: #248a49;
}
.event-card__image-wrap[class^="event-card__image-wrap four"] {
    background-color: #7744F3;
}
.event-card__image-wrap[class^="event-card__image-wrap five"] {
    background-color: #F7D15F;
}
.event-card__image-wrap[class^="event-card__image-wrap six"] {
    background-color: #F7D15F;
}
.event-card__image-wrap[class^="event-card__image-wrap seven"] {
    background-color: #F7D15F;
}
/* -------------- */


   
.query-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 0rem;
}

.query-wrapper > div {
  flex: 1 1 x250px;   /* grow/shrink, but don't go below 250px before wrapping */
  min-width: 0;       /* prevents flex children overflowing on long labels */
}

.category, .region {
    xmax-width: 20%;
/*    margin-left: 1em; */
}
.keyword {
    xmin-width: 40%;
    padding-right: 1em;
}
.query-filter li {
    padding-bottom: 0;
}
.query-filter li label {
    padding-left: 0.5em;
}
.category ul {
        padding-right: 2em;

}
option {
    display: list;
}
.dhs-container:after {
    clear: both;
}
.event-card__link {
    font-size: 0.95em !important;
    color: #415866 !important;
    margin-top: 0 !important;
}
/* ================================================================================ */   
#queries_keyword_query, #queries_format_query, #queries_language_query {
    width: 100%;
    padding-top: 0.5em;
}
    /*/ filter boxes styles */

    .flex-container {
        display: flex;
        flex-direction: row;
        column-gap: 1em;
        border-radius: 10px;
    }
    .flex-25, .flex-33, .flex-50, .flex-75, .flex-100 {
        border-radius: 10px;
        padding: 0.5em 1em;
       /* margin-bottom: 1em; */
    }
    .flex-25 {
        width: 25%;
    }
    .flex-33 {
        width: 31%;
    }
    .flex-50 {
        width: 50%;
    }
    .flex-66 {
        width: 66%;
    }
    .flex-75 {
        width: 75%;
    }
    .flex-100 {
        width: 100%;
    }
    @media (max-width: 767px) {
        .flex-25, .flex-33, .flex-50, .flex-75 {
            width: 100%;
        }
        .flexcontainer {
            flex-direction: column;
        }
    }




.query-wrapper {
    display: flex;
    margin-bottom: 1em;
}
/* .query-wrapper div {
    margin-right: 1em;
} */
.flex33 {
    width: 33%;
}
@media (max-width:600px) {
    .query-wrapper {
        flex-direction: column;
    }
.flex25, .flex33, .flex50, .flex75 .flex50 {
        width: 100% !important;
    }
}
.age {
    border: 1px solid #001;
    border-radius: 5px;
    width: fit-content;
    padding: 14px;
    margin-top: 3px;
}

/* Fields and labels */
#age-query label, .age-query label {
    margin-left: 0.3em;
}
.cat-list ul {margin: 1em;
}
.cat-style {
    background: #fff;
    border: 1px solid #000;
    border-radius: 5px;
    padding: 1em;
    margin-top: 5px;
}
.qf-label {
    font-family: Mulish, Public Sans, Arial;
    color: #001;
}
summary {
    font-weight: 600;
        font-family: Mulish, Public Sans, Arial;
}
.sq-form-field {
    padding: 12px;
    margin-top: 3px;
        font-family: Mulish, Public Sans, Arial;
}

.form-actions {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
}

/* Buttons */
.subButtons {
    margin-top: 1.5em;
}
.reset-button {
    padding: 11px 16px;
    font-size: 18px;
    border-radius: 5px;
    border: 2px solid #000;
    background: #f1f1f1;
    color: #0a2340;
    cursor: pointer;
    font-weight: 600;
    display: inline;
    margin-left: 12px;
}
.reset-button:hover {
    border: 2px solid #f04f71;
    background: #f04f71;
    color: #fff;
}
input[type=submit] {
    border: 2px solid #0a2340;
}
input[type=submit]:hover {
    border: 2px solid #f04f71;
}
#filter > div.subButtons > p > input[type=submit]:nth-child(2) {
    padding : 11px 20px;
}
.filter-results {
    width: 100%;
    display: inline-block;
    padding: 1.5rem 0;
}
#filter ul {
    list-style: none;
}
#filter ul > li {
    margin-left: -1em;
}
.applied-filters {
    font-weight: bold;
    color: #0a2340;
}

/* END Styles - Initial search page */

/* Styles - Results page layout */



/* END Styles - Results page layout */
