.evge-calendar-form{
    background: #f6f6f6;
    border: 1px solid #dcdcdc;
    border-top: none;
}
.evge-calendar-builder {
    display: flex;
    gap: 2rem;
    padding: 2rem 20px 2rem 0;
    max-width: 1600px;
}
.evge-builder-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}
.evge-calendar-builder-sidebar {
    flex: 1 1 400px;
    min-width: 300px;
    max-width: 500px;
    padding: 1.5rem;
}
.evge-calendar-builder-preview {
    background: #fff;
    padding: 1.5rem;
    min-width: 300px;
    width: 100%;
    max-width: 800px;
    box-sizing: border-box;
    position: relative;
}
.evge-calendar-builder-preview .evge-bulk-select-button {
    background: #1A79C1;
}
.evge-builder-section {
    margin-bottom: 2rem;
}
.evge-calendar-builder-preview .evge-event-date{
    max-height: 70px;
    min-width: 50px;
}
.evge-calendar-builder-preview .evge-event-list-item {
    gap: 25px;
}
.evge-calendar-builder-preview .evge-filter-group:first-child {
    flex: 8;
}

.evge-builder-section h3 {
    margin: 0 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #eee;
}

.evge-builder-field {
    margin-bottom: 1.5rem;
    display: grid;
    grid-template-columns: 120px 1fr;
    align-items: center;
    gap: 1rem;
}

.evge-builder-field label {
    margin-bottom: 0;
    font-weight: 600;
    color: #1d2327;
}

.evge-filter-bar-options-list {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-top: 5px;
}

.evge-filter-bar-options-list label {
    font-weight: normal;
}

.evge-sub-label {
    font-weight: bold;
}

/* Bulk registration message - positioned below the field */
.evge-builder-field-bulk-registration {
    align-items: start;
}

.evge-bulk-registration-message {
    grid-column: 1 / -1;
    margin-top: 0.5rem;
    font-size: 13px;
    color: #50575e;
}
.evge-visually-hidden{
    visibility: hidden;
}

/* Input styling */
.evge-builder-field input[type="text"],
.evge-builder-field input[type="number"],
.evge-builder-field input[type="color"],
.evge-builder-field select {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 3px 10px;
    border-color: #dcdcdc;
}
.evge-builder-field input[type="number"]{
    width: 50%;
}
.evge-builder-field select,
.evge-builder-field .evge-builder-field-view-type select {
    width: auto;
    padding-right: 30px;
}

/* Color input specific styling */
.evge-builder-field input[type="color"] {
    padding: 0;
    height: 30px;
}

/* Responsive Layout */
@media screen and (max-width: 782px) {
    .evge-builder-field {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .evge-builder-field label {
        margin-bottom: 0.5rem;
    }
}

.evge-builder-field select[multiple] {
    height: 120px;
}

.evge-preview-header {
    margin-bottom: 1.5rem;
    padding-bottom: 0.8rem;
    border-bottom: 1px solid #dcdcdc;
    display: flex;
    justify-content: space-between;
}

.evge-preview-header h3 {
    margin: 0;
}
.evge-preview-header a{
    text-decoration: none;
}
.evge-preview-header a svg{
    height: 9px;
    margin-left: 4px;
}

.evge-preview-message {
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 4px;
    font-size: 14px;
}

.evge-message-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.evge-message-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.evge-calendar-filters .evge-search-input,
.evge-calendar-filters .evge-venue-select,
.evge-calendar-filters .evge-view-select {
    box-sizing: border-box;
    border: 1px solid #dcdcdc;
    border-radius: 4px;
    font-size: 14px;
    width: 100%;
    max-width: 200px;
}

@media screen and (max-width: 1400px) {
    .evge-calendar-filters .evge-search-input, .evge-calendar-filters .evge-venue-select, .evge-calendar-filters .evge-view-select {
        min-width: 105px;
    }
}
@media screen and (max-width: 1100px) {
    .evge-filter-group:first-child,
    .evge-calendar-filters{
        gap: 5px;
    }
}
@media screen and (max-width: 1000px) {
    .evge-calendar-builder{
        display: block;
    }
}
@media screen and (max-width: 1420px) {
    .evge-visually-hidden {
        display: none;
    }
    .evge-builder-field.evge-filter-builder-wrapper {
        display: block;
    }
}

/* Select2 Customization */

.evge-builder-field .select2-container .select2-selection--multiple {
    border-color: #8c8f94;
}

.evge-builder-field .select2-container .select2-selection--multiple .select2-selection__choice {
    background-color: #f0f0f1;
    border-color: #c3c4c7;
    color: #3c434a;
}

.evge-admin-page .evge-builder-actions .evge-admin-primary-button,
.evge-admin-page .evge-builder-actions .evge-admin-secondary-button {
    padding: 12px 20px;
    font-size: 14px;
}
.evge-admin-page .evge-builder-actions svg{
    position: relative;
    top: 1px;
}

.evge-builder-field input[type="text"] {
    width: 100%;
}

/* Filter Builder */
.evge-filter-item {
    background: #F3F3F3;
    border: 1px solid #dcdcdc;
    padding: 10px;
    border-radius: 5px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}
.evge-filter-item:last-child{
    margin-bottom: 10px;
}

.evge-filter-summary {
    flex: 1;
}
.evge-filter-content{
    display: flex;
    gap: 2px;
}

.evge-filter-step-1,
.evge-filter-step-2 {
    margin-bottom: 15px;
}

.evge-filter-builder label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}

.evge-filter-builder select,
.evge-filter-builder input[type=text]{
    width: 100%;
    max-width: 100%;
    margin-bottom: 0;
    padding: 3px 10px;
    border-color: #dcdcdc;
}

.evge-filter-content .evge-filter-terms{
    margin: 0;
}

.evge-filters-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.evge-filter-builder select {
    width: auto;
    padding-right: 30px;
}

.evge-filters-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.evge-add-filter {
    align-self: flex-start;
}
.evge-remove-filter{
    background: none;
    border: 0;
    outline: 0;
}
.evge-remove-filter:hover,
.evge-remove-filter:active{
    cursor: pointer;
}
.evge-remove-filter:hover path,
.evge-remove-filter:active path{
    fill: #666;
}

/* Select2 Customization */
.evge-filter-builder .select2-container {
    max-width: 100%;
    border-color: #dcdcdc;
}
.evge-filter-builder .select2-container--default .select2-selection--single .select2-selection__arrow {
    top: 5px;
}
.evge-filter-builder .select2-container--default .select2-selection--single {
    height: 36px;
    border-color: #dcdcdc;
    border-radius: 3px;
    line-height: 1.2;
    padding: 3px 0;
}
.evge-filter-terms .select2-container--default .select2-search--inline .select2-search__field:placeholder {
    color: #2c3338;
}
.evge-filter-terms .select2-container--default .select2-search--inline .select2-search__field {
    font-size: 14px;
    margin-left: 0;
    text-align: center;
}

/* Responsive adjustments */
@media screen and (max-width: 782px) {
    .evge-filter-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .evge-filter-item .button {
        width: 100%;
        text-align: center;
    }
}


/**
OVERVIEW PAGE
 */
.evge-calendar-filter-bar {
    display: flex;
    justify-content: space-between;
}
.evge-calendar-filter-bar .evge-search-form {
    margin: 0;
}

.evge-calendar-filter-bar .tablenav .tablenav-pages .button,
.evge-calendar-filter-bar .tablenav .tablenav-pages .tablenav-pages-navspan,
.evge-calendar-filter-bar .tablenav #table-paging{
    margin-right: 2px;
}
.evge-calendar-filter-bar .tablenav .displaying-num{
    margin-left: 7px;
}
.evge-calendar-filter-bar .evge-search-box{
    gap: 0;
}
.evge-calendar-filter-bar .search-box{
    position: relative;
}
.evge-calendar-filter-bar .evge-search-box input{
    padding: 2px 10px 2px 36px;
    border-color: #DCDCDC;
}
.evge-calendar-filter-bar .evge-search-box .evge-toolbar-icon{
    position: absolute;
    z-index: 1;
    left: 15px;
    top: 50%;
    margin-top: -9px;
}
.evge-calendar-filter-bar .evge-search-box svg{
    width: 13px;
}


/* Calendar-specific grid override - uses larger min-width for calendar cards */
.evge-items-grid {
    max-width: 1600px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(450px, 1fr));
    gap: 20px;
    margin: 20px 0;
    clear: both;
    border-radius: 5px;
}

/* Calendar-specific styles */
.evge-item-title .evge-calendar-color-dot{
    margin-right: 3px;
}
.evge-item-card-top .evge-calendar-id{
    font-family: monospace;
    color: #555;
    background: #F0F0F1;
    font-size: 12px;
    padding: 2px 5px;
    line-height: 1.5;
    border-radius: 5px;
    margin-left: 3px;
    min-width: 42px;
    white-space: nowrap;
}

.evge-embed-code {
    margin-top: 10px;
    padding: 10px;
    background: #f0f0f1;
    border-radius: 3px;
}

.evge-no-items {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px;
    background: #fff;
    border: 1px solid #ccd0d4;
    border-radius: 4px;
}

.evge-pagination {
    margin: 20px 0;
    text-align: right;
}

.wp-core-ui .evge-item-card-section {
    margin: 0;
    padding: 12px 20px;
    flex-wrap: nowrap;
}
.wp-core-ui .evge-item-card-header{
    flex-wrap: nowrap;
}



.evge-events-preview {
    margin: 0;
    padding: 0;
    list-style: none;
}

.evge-preview-event {
    margin-bottom: 12px;
    display: flex;
    gap: 2px;
    flex-direction: column;
}

.evge-preview-date {
    color: #333;
    font-size: 0.9em;
    white-space: nowrap;
}
.evge-preview-venue{
    border-left: 1px solid #aaa;
    margin-left: 5px;
    padding-left: 8px;
}


.evge-view-all {
    margin: 0;
    padding: 5px 0 10px 0;
    font-size: 1em;
}
.evge-view-all a{
    text-decoration: none;
}

.evge-no-events {
    color: #666;
    font-style: italic;
    margin: 0;
}
.evge-calendar-color-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
    border: 1px solid #ccd0d4; /* Added border to make transparent dots visible */
}

.evge-preview-title {
    text-decoration: none;
    font-size: 15px;
}

/* Responsive adjustments */
@media screen and (max-width: 782px) {
    .evge-add-filter {
        width: 100%;
        text-align: center;
    }
}

/* Align filter label to top */
.evge-field-filters-top {
    align-items: start; /* This aligns items to the top */
}

/* If you need to specifically align just the label */
.evge-field-filters-top > label {
    margin-top: 4px; /* Optional: Add a small offset if needed */
}

#evge-calendar-builder-nav.evge-main-admin-subnav {
    background: #fff;
    border: 1px solid #dcdcdc;
    border-radius: 5px 5px 0 0;
    margin: 15px 0 0 0;
    padding-left: 10px;
}
#evge-calendar-builder-nav .evge-main-admin-subnav-inner{
    border: 0;
}
#evge-calendar-builder-nav .evge-subnav-tab{
    margin: 0;
}

.evge-shortcode-container {
    background: #f0f0f1;
    padding: 1rem;
    border-radius: 4px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin: 1rem 0;
}

.evge-shortcode {
    font-family: monospace;
    color: #1d2327;
}
.evge-cal-shortcode p{
    font-size: 1rem;
}

.evge-builder-section code{
    padding: 10px;
}

.evge-copy-success {
    color: #00a32a;
    margin-top: 0.5rem;
}
.evge-cal-shortcode .evge-copy-success{
    background: #d4edda;
    color: #155724;
    border: 1px solid #a5cdae;
    padding: 7px 10px;
    border-radius: 5px;
}

.evge-builder-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0.5rem 0;
}

.evge-builder-title h1 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.evge-builder-settings-wrap table.widefat{
    box-shadow: none;
    border: 1px solid #dcdcdc;
    border-left: 0;
    border-right: 0;
}
.evge-builder-settings-wrap table.widefat,
.evge-builder-settings-wrap .widefat thead td,
.evge-builder-settings-wrap .widefat thead th{
    border-color: #dcdcdc;
}
.evge-builder-settings-wrap{
    border: 1px solid #dcdcdc;
    border-top: 0;
    border-radius: 0 0 5px 5px;
    background: #f6f7f7;
}
.evge-builder-settings-wrap .evge-event-search input[type=search] {
    padding: 0 10px 0 36px;
    border-color: #DCDCDC;
}
.evge-builder-settings-wrap .tablenav {
    display: flex;
    justify-content: space-between;
    margin: 0;
    padding: 8px;
}
.evge-builder-settings-wrap .tablenav .actions{
    padding: 0;
}
.evge-builder-settings-wrap .evge-event-search{
    position: relative;
}
.evge-builder-settings-wrap .evge-event-search .evge-toolbar-icon{
    position: absolute;
    z-index: 1;
    left: 15px;
    top: 50%;
    margin-top: -9px;
}
.evge-builder-settings-wrap .evge-event-search .evge-toolbar-icon svg{
    width: 13px;
}
.evge-builder-settings-wrap .tablenav .tablenav-pages{
    float: none;
}
.evge-builder-settings-wrap .tablenav-pages a,
.evge-builder-settings-wrap .tablenav-pages span{
    display: inline-block;
    min-width: 30px;
    min-height: 30px;
    margin: 0;
    padding: 4px;
    font-size: 13px;
    line-height: 1.625;
    text-align: center;
    color: #666;
    background: #f9f9f9;
    border: 1px solid #bbb;
    border-radius: 3px;
    box-sizing: border-box;
    text-decoration: none;
}
.evge-builder-settings-wrap .tablenav-pages span{
    border-color: #ccc;
    background-color: #eee;
}
.evge-builder-settings-wrap .tablenav-pages a.next,
.evge-builder-settings-wrap .tablenav-pages a.prev{
    padding-left: 8px;
    padding-right: 8px;
}
.evge-builder-settings-wrap .tablenav-pages a{
    cursor: pointer;
}
.evge-builder-settings-wrap .tablenav-pages a:hover,
.evge-builder-settings-wrap .tablenav-pages a:active{
    background: #fff;
    border-color: #aaa;
}

/* Responsive adjustments */
@media screen and (max-width: 550px) {
    .wp-core-ui .evge-item-card-section {
        flex-wrap: wrap;
        gap: 15px;
    }
    .evge-items-grid{
        grid-template-columns: repeat(auto-fill, minmax(100%, 1fr));
    }
}

/** Frontend Overrides */
.evge-calendar-builder .evge-grid-layout {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}