/* Custom Accordion header styling */

#eventlist h3 {
    font-size: 2rem;
    margin: 0;
    background-color: #007bff;
    color: #fff;
    padding: 0.2rem;
    /*border: 1px solid #DDDDDD;*/
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    position: relative;
    padding: 0.3rem;
    padding-right: 2.2rem; /* space for the chevron icon */

}


#eventlist h3 .accordeon_icon {
    font-size: 2rem;
    height: 2rem;
    width: 2rem;
    border: 0;
    margin-right: 0.2rem;
    opacity: 0.5;
}

#eventlist h3 .accordeon_day {
    /*font-size:0.7rem*/;
    font-weight:bold;
    /*margin-left:2rem;*/
    font-family:sans-serif;
    margin-right: 0.2rem;
    /*position:absolute;top:-0.7rem;*/
    opacity: 0.5;
}

/* Ensuring the header text does not break onto a new line */
#eventlist h3 .header-text {
    font-size: 1rem;
    display: inline-block;
    /*white-space: nowrap;   */
}

/* Pseudo-element for accordion icons */
#eventlist h3::after {
    font-family: dashicons;
    /* Use dashicons for a downward pointing arrow (closed state) */
    content: "\f347" ; /*"\f140"; f347 Check your dashicons reference; adjust as needed */
    position: absolute;
    right: 0.2rem;
    top: 50%;
    transform: translateY(-50%);
    /*font-size: 2em;*/
    transition: transform 0.3s ease;
}

/* When the accordion panel is open, the header gets the active class */
#eventlist .ui-accordion-header-active::after {
    content: "\f347" ; /* Dashicons for upward pointing arrow; adjust if necessary */
    /* Optionally, rotate the icon */
    transform: translateY(-50%) rotate(180deg);
}

/* Custom Accordion panel styling */
#eventlist div {
    border: 1px solid #DDDDDD;
    border-top: none;
    /*padding: 1rem; */
    background-color: #fff;
}

#eventlist .eventlist_daytime {
    /*position:relative;top:-0.8rem;*/
    font-size: 0.9rem;
    border-radius: 0.5rem;
    padding: 0.4rem;
    margin: 0;
    opacity: 0.7;
}

#eventlist h2 { font-size: 1.4rem; }

#eventlist .ter_kal_button {
    width: 90%;
}

    .duplicate_info {
        font-size: 0.7rem;
        color: #666666;
    }

/* ============================================
   CONTAINER-BASED RESPONSIVE SCALING
   ============================================ */

#eventlist
 {
    container-type: inline-size;
    container-name: tk-block;
}
/* Small containers (< 400px) - Widget areas */
@container tk-block (max-width: 400px) {

    /* Simple/Extended List */
    #eventlist h3::after { font-size: 1rem; }
    #eventlist h2 { font-size: 1rem;}
    #eventlist h3 .header-text,
    #eventlist .ui-accordion-content,
    #eventlist button { font-size: 0.7rem; line-height: 1.4rem; padding:0.4rem;}
    #eventlist h3 .accordeon_day,
    #eventlist .accordeon_icon { display: none; }
    #eventlist h3,
    #eventlist div {  padding-right: 1rem;}


}  /* end Small containers */

/* Medium containers (400px - 768px) - Adjustments if needed */
@container tk-block (min-width: 400px) and (max-width: 768px) {
  /*#eventlist .header-text { font-size: 0.6rem; } */
}
