/* ==========================================================================
   LAYE Pro — Public events catalogue
   ========================================================================== */

/* ---------- Hero ---------- */
.ev-hero {
    position: relative; isolation: isolate; overflow: hidden;
    margin-top: var(--lp-header-h); padding: 48px 0 40px;
    background: #0d0d10; color: #fff; border-radius: 0 0 32px 32px;
}
.ev-hero-glow {
    position: absolute; inset: 0; z-index: -1;
    background:
        radial-gradient(circle at 82% 20%, rgba(255, 113, 64, .45), transparent 38%),
        radial-gradient(circle at 60% 120%, rgba(244, 71, 42, .35), transparent 45%);
}
.ev-hero-inner { display: grid; gap: 24px; }
.ev-hero-title { margin: 16px 0 10px; font: 800 clamp(30px, 4vw, 46px)/1.08 var(--lp-display); letter-spacing: -0.03em; color: #fff; }
.ev-hero-title span { background: linear-gradient(95deg, #ff6a3d, #ffa66b); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ev-hero-sub { margin: 0; color: rgba(255, 255, 255, .74); font-size: 16px; max-width: 560px; }

.ev-search {
    display: flex; gap: 10px; align-items: center; max-width: 860px; padding: 8px;
    background: #fff; border-radius: 20px; box-shadow: 0 30px 60px -24px rgba(0, 0, 0, .65);
}
.ev-search-field { position: relative; flex: 1; display: flex; align-items: center; gap: 12px; padding: 0 8px; min-width: 0; }
.ev-search-field input {
    flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; height: 48px;
    font: 400 15px var(--lp-font); color: var(--lp-text, #16161a);
}
.ev-search-field input::placeholder { color: var(--lp-muted); }
.ev-search-field input::-webkit-search-cancel-button { display: none; }
.ev-search .search-clear {
    width: 32px; height: 32px; border: 0; border-radius: 50%; background: var(--lp-bg, #f7f6f4); color: var(--lp-muted); cursor: pointer;
}
.ev-search-submit { height: 52px; border-radius: 14px; }
.ev-counts { display: flex; gap: 22px; flex-wrap: wrap; color: rgba(255, 255, 255, .66); font-size: 14px; }
.ev-counts strong { color: #fff; font: 800 16px var(--lp-display); margin-right: 4px; }

@media (max-width: 640px) {
    .ev-hero { padding: 32px 0 28px; border-radius: 0 0 24px 24px; }
    .ev-search-submit span { display: none; }
    .ev-search-submit { width: 52px; padding: 0; }
    .ev-search-field .h-search-icon { display: none; }
    .ev-counts { gap: 14px; font-size: 13px; }
}

/* ---------- Layout ---------- */
.events-catalogue { padding: 26px 0 64px; }
.ev-layout { display: grid; grid-template-columns: 272px minmax(0, 1fr); gap: 24px; align-items: start; }

/* Filters */
.ev-filters {
    position: sticky; top: calc(var(--lp-header-h) + 16px);
    background: #fff; border: 1px solid var(--lp-line); border-radius: var(--lp-radius-lg); box-shadow: var(--lp-shadow-sm);
}
.ev-filters-head {
    list-style: none; display: flex; align-items: center; justify-content: space-between; cursor: pointer;
    padding: 18px 20px; font: 800 17px var(--lp-display); color: var(--lp-text, #16161a);
}
.ev-filters-head::-webkit-details-marker { display: none; }
.ev-filters-head > span { display: inline-flex; align-items: center; gap: 10px; }
.ev-filters-head > span i { color: var(--lp-text-2); font-size: 15px; }
.ev-filters-caret { font-size: 12px; color: var(--lp-muted); transition: transform .2s ease; display: none; }
.ev-filters[open] .ev-filters-caret { transform: rotate(180deg); }
.ev-filters-body { padding: 0 20px 20px; display: grid; gap: 22px; }
.ev-filter-group { display: grid; gap: 10px; padding-top: 18px; border-top: 1px solid var(--lp-line); }
.ev-filter-title { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 14.5px; color: var(--lp-text, #16161a); }
.ev-filter-title i { color: var(--lp-brand); width: 16px; }

.ev-radio-list { display: grid; gap: 4px; }
.ev-radio-list .filter-pill {
    display: flex; align-items: center; gap: 12px; padding: 8px 6px; border: 0; background: transparent; border-radius: 10px;
    font: 500 14px var(--lp-font); color: var(--lp-text-2); text-align: left; cursor: pointer;
}
.ev-radio-list .filter-pill:hover { background: var(--lp-bg, #f7f6f4); }
.ev-radio { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--lp-line-2); flex-shrink: 0; position: relative; transition: border-color .2s ease; }
.ev-radio-list .filter-pill.active { color: var(--lp-text, #16161a); font-weight: 600; }
.ev-radio-list .filter-pill.active .ev-radio { border-color: var(--lp-brand); }
.ev-radio-list .filter-pill.active .ev-radio::after { content: ''; position: absolute; inset: 3px; border-radius: 50%; background: var(--lp-brand); }

.ev-select { position: relative; }
.ev-select::after {
    content: ''; position: absolute; right: 14px; top: 50%; width: 8px; height: 8px; margin-top: -6px; pointer-events: none;
    border-right: 1.6px solid var(--lp-muted); border-bottom: 1.6px solid var(--lp-muted); transform: rotate(45deg);
}
.ev-select select {
    width: 100%; height: 44px; padding: 0 36px 0 14px; border: 1px solid var(--lp-line-2); border-radius: 12px; background: #fff;
    font: 500 14px var(--lp-font); color: var(--lp-text, #16161a); appearance: none; -webkit-appearance: none; cursor: pointer;
}
.ev-select select:focus { outline: 0; border-color: var(--lp-brand); box-shadow: 0 0 0 3px rgba(244, 81, 44, .14); }
.ev-reset {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; border-radius: 12px; border: 1px dashed var(--lp-line-2);
    background: transparent; color: var(--lp-brand-600); font: 600 14px var(--lp-font); cursor: pointer;
}
.ev-reset:hover { background: var(--lp-brand-50); border-color: var(--lp-brand-100); }

/* Results */
.ev-results-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.ev-results-title { margin: 0 0 4px; font: 800 24px var(--lp-display); color: var(--lp-text, #16161a); }
.results-count { color: var(--lp-muted); font-size: 14px; }
.results-count strong { color: var(--lp-text, #16161a); }
.ev-results-tools { display: flex; align-items: center; gap: 12px; }
.ev-sort { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--lp-text-2); }
.ev-select-inline select { min-width: 170px; height: 42px; }
.view-toggle { display: inline-flex; padding: 3px; gap: 3px; background: #fff; border: 1px solid var(--lp-line); border-radius: 12px; }
.view-btn { width: 38px; height: 34px; border: 0; border-radius: 9px; background: transparent; color: var(--lp-muted); cursor: pointer; }
.view-btn.active { background: var(--lp-grad, linear-gradient(100deg, #f4472a 0%, #ff7140 100%)); color: #fff; }

.active-filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.active-filters[hidden] { display: none; }
.active-filter-chip {
    display: inline-flex; align-items: center; gap: 8px; padding: 6px 6px 6px 12px; border-radius: 999px;
    background: var(--lp-brand-50); color: var(--lp-brand-700); font-size: 13px; font-weight: 600;
}
.active-filter-chip button { width: 22px; height: 22px; border: 0; border-radius: 50%; background: rgba(244, 81, 44, .14); color: inherit; cursor: pointer; font-size: 11px; }

/* Grid + cards */
.events-loading { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.events-list.is-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.events-list .lp-ecard { animation: evIn .4s ease both; }
@keyframes evIn { from { opacity: 0; transform: translateY(8px); } }

.lp-ecard .event-share-btn {
    position: absolute; top: 12px; right: 12px; z-index: 3; width: 36px; height: 36px; border-radius: 50%; border: 0; cursor: pointer;
    background: rgba(255, 255, 255, .92); color: var(--lp-text, #16161a); box-shadow: 0 6px 14px -8px rgba(0, 0, 0, .5);
    display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .2s ease, transform .2s ease;
}
.lp-ecard:hover .event-share-btn, .lp-ecard .event-share-btn:focus-visible { opacity: 1; }
@media (hover: none) { .lp-ecard .event-share-btn { opacity: 1; } }
.lp-ecard .lp-ecard-tag { top: auto; bottom: 12px; right: auto; left: 12px; }

.ev-card-when { display: flex; gap: 7px; align-items: center; margin: 0; font-size: 13px; color: var(--lp-muted); }
.ev-card-when i { color: var(--lp-brand); font-size: 12px; }
.event-card-description { display: none; margin: 2px 0 0; font-size: 14px; color: var(--lp-text-2); line-height: 1.55; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.event-card-footer { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 6px; }
.event-card-footer .lp-ecard-price { margin: 0; padding: 0; }
.event-card-cta {
    position: relative; z-index: 2; display: none; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 999px;
    background: var(--lp-grad, linear-gradient(100deg, #f4472a 0%, #ff7140 100%)); color: #fff; font-weight: 600; font-size: 14px; text-decoration: none; box-shadow: var(--lp-shadow-brand);
}
.event-card-cta i { font-size: 12px; }

.event-availability { display: none; margin-top: 4px; }
.availability-head { display: flex; justify-content: space-between; gap: 8px; font-size: 12.5px; color: var(--lp-muted); }
.availability-head strong { color: var(--availability-color, var(--lp-success)); font-weight: 700; }
.availability-track { margin-top: 6px; height: 5px; border-radius: 999px; background: var(--lp-bg, #f7f6f4); overflow: hidden; }
.availability-fill { width: var(--availability-progress, 0%); height: 100%; border-radius: inherit; background: var(--availability-color, var(--lp-success)); }

/* List view */
.events-list.is-list { display: grid; gap: 16px; }
.events-list.is-list .lp-ecard { flex-direction: row; }
.events-list.is-list .lp-ecard-media { flex: 0 0 300px; aspect-ratio: auto; min-height: 210px; }
.events-list.is-list .lp-ecard-body { padding: 20px 22px; gap: 9px; }
.events-list.is-list .lp-ecard-title { font-size: 19px; }
.events-list.is-list .event-card-description { display: -webkit-box; }
.events-list.is-list .event-availability { display: block; max-width: 420px; }
.events-list.is-list .event-card-cta { display: inline-flex; }
@media (max-width: 720px) {
    .events-list.is-list .lp-ecard { flex-direction: column; }
    .events-list.is-list .lp-ecard-media { flex-basis: auto; aspect-ratio: 16 / 10; min-height: 0; }
}

/* States */
.catalogue-state { padding: 56px 24px; text-align: center; background: #fff; border: 1px dashed var(--lp-line-2); border-radius: var(--lp-radius-lg); }
.catalogue-state[hidden] { display: none; }
.state-icon { width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--lp-brand-50); color: var(--lp-brand); font-size: 24px; }
.catalogue-state h2 { font: 800 20px var(--lp-display); margin: 0 0 8px; color: var(--lp-text, #16161a); }
.catalogue-state p { margin: 0 0 20px; color: var(--lp-muted); }

/* Pagination */
.pagination { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: 32px; flex-wrap: wrap; }
.pagination:empty { display: none; }
.page-btn {
    min-width: 42px; height: 42px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--lp-line); background: #fff;
    font: 600 14px var(--lp-font); color: var(--lp-text, #16161a); cursor: pointer; transition: all .2s ease;
}
.page-btn:hover:not(:disabled) { border-color: var(--lp-brand); color: var(--lp-brand-600); }
.page-btn.active { background: var(--lp-grad, linear-gradient(100deg, #f4472a 0%, #ff7140 100%)); border-color: transparent; color: #fff; box-shadow: var(--lp-shadow-brand); }
.page-btn:disabled { opacity: .45; cursor: not-allowed; }
.page-dots { color: var(--lp-muted); padding: 0 4px; }

/* Toast */
.share-toast {
    position: fixed; left: 50%; bottom: 28px; z-index: 2000; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
    padding: 12px 18px; border-radius: 12px; background: var(--lp-ink, #111114); color: #fff; font-size: 14px; box-shadow: var(--lp-shadow-lg);
    transition: opacity .2s ease, transform .2s ease;
}
.share-toast.visible { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .ev-layout { grid-template-columns: minmax(0, 1fr); gap: 16px; }
    .ev-filters { position: static; }
    .ev-filters-caret { display: inline-block; }
    .ev-filters-head { padding: 14px 18px; font-size: 16px; }
    .ev-filters-body { grid-template-columns: 1fr 1fr; gap: 16px; }
    .ev-filter-group:first-child { grid-column: 1 / -1; }
    .ev-radio-list { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
    .ev-filters-body { grid-template-columns: 1fr; }
    .ev-results-head { align-items: stretch; }
    .ev-results-tools { width: 100%; justify-content: space-between; }
    .ev-sort > span:first-child { display: none; }
    .ev-select-inline select { min-width: 0; }
    .events-list.is-grid, .events-loading { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .events-list.is-grid .lp-ecard-body { padding: 10px 12px 12px; gap: 5px; }
    .events-list.is-grid .lp-ecard-title { font-size: 14px; }
    .events-list.is-grid .ev-card-when { display: none; }
    .events-list.is-grid .lp-ecard-loc { font-size: 12px; }
    .events-list.is-grid .lp-date { top: 8px; left: 8px; min-width: 42px; padding: 5px 6px; }
    .events-list.is-grid .lp-date strong { font-size: 16px; }
    .events-list.is-grid .lp-ecard-tag { display: none; }
}
