/* EventChamp Pagination – frontend styles */

.ecp-event-grid {
    display: grid;
    gap: 30px;
    margin: 30px 0;
}
.ecp-cols-1 { grid-template-columns: 1fr; }
.ecp-cols-2 { grid-template-columns: repeat(2, 1fr); }
.ecp-cols-3 { grid-template-columns: repeat(3, 1fr); }
.ecp-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 991px) {
    .ecp-cols-3, .ecp-cols-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    .ecp-cols-2, .ecp-cols-3, .ecp-cols-4 { grid-template-columns: 1fr; }
}

.ecp-event-card {
    background: #fff;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    transition: transform .25s ease, box-shadow .25s ease;
}
.ecp-event-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}
.ecp-event-thumb { display: block; }
.ecp-event-thumb img { width: 100%; height: auto; display: block; }
.ecp-event-body { padding: 18px 20px 22px; }
.ecp-event-date {
    font-size: 13px;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}
.ecp-event-title {
    font-size: 18px;
    margin: 0 0 8px;
    line-height: 1.3;
}
.ecp-event-title a { color: inherit; text-decoration: none; }
.ecp-event-title a:hover { color: #e74c3c; }
.ecp-event-location { font-size: 13px; color: #666; }

/* Pagination - numbered */
.ecp-pagination {
    margin: 40px 0 20px;
    text-align: center;
}
.ecp-pagination ul {
    display: inline-flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
}
.ecp-pagination li { margin: 0; }
.ecp-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border-radius: 4px;
    background: #f4f4f4;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    transition: all .2s ease;
}
.ecp-pagination .page-numbers:hover {
    background: #e74c3c;
    color: #fff;
}
.ecp-pagination .page-numbers.current {
    background: #e74c3c;
    color: #fff;
    cursor: default;
}
.ecp-pagination .page-numbers.dots {
    background: transparent;
    cursor: default;
}

/* Pagination - prev / next */
.ecp-prev-next {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 20px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}
.ecp-prev-next .ecp-prev,
.ecp-prev-next .ecp-next { flex: 1; }
.ecp-prev-next .ecp-next { text-align: right; }
.ecp-prev-next .ecp-page-info { color: #888; font-size: 14px; }
.ecp-prev-next a {
    display: inline-block;
    padding: 8px 18px;
    background: #f4f4f4;
    color: #333;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    transition: all .2s ease;
}
.ecp-prev-next a:hover { background: #e74c3c; color: #fff; }

/* Load More */
.ecp-load-more-wrap { text-align: center; margin: 30px 0; }
.ecp-load-more {
    background: #e74c3c;
    color: #fff;
    border: 0;
    padding: 12px 32px;
    font-size: 15px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background .2s ease;
}
.ecp-load-more:hover:not(:disabled) { background: #c0392b; }
.ecp-load-more:disabled { opacity: 0.6; cursor: not-allowed; }

.ecp-no-events { padding: 30px; text-align: center; color: #888; }

/* Loading overlay during AJAX page swaps */
.ecp-events-wrap { position: relative; }
.ecp-events-wrap.ecp-loading .ecp-event-grid { opacity: 0.4; transition: opacity .2s ease; }
.ecp-loading-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 80px;
    pointer-events: none;
    z-index: 5;
}
.ecp-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid rgba(0,0,0,0.1);
    border-top-color: #e74c3c;
    border-radius: 50%;
    animation: ecp-spin 0.8s linear infinite;
}
@keyframes ecp-spin { to { transform: rotate(360deg); } }

/* Color override hook — site can change accent in customizer/CSS:
   :root { --ecp-accent: #yourcolor; }
   then update the rules above to use var(--ecp-accent, #e74c3c) if needed. */
