/* ============================================================
   Places page — filter search container
   ============================================================ */
.sa-places-search-container {
    width: 100%;
    margin-bottom: 20px;
}

.events-search-container {
    justify-content: flex-start;
}

.js-places-filter-form {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-bottom: 0;
    width: 100%;
}

.js-no-results-notification {
    grid-column: 1 / 4;
}

.intro-block {
    background: #FBF485;
    border-radius: 12px;
    padding: clamp(18px, 4vw, 28px) clamp(16px, 4vw, 32px);
    margin: 16px 0 24px;
}
.intro-block h2 {
    font-size: clamp(16px, 3vw, 20px);
    font-weight: 800;
    margin-bottom: 10px;
    color: #1a1a1a;
    line-height: 1.3;
}
.intro-block p {
    font-size: clamp(13px, 2.5vw, 14.5px);
    color: #444;
    line-height: 1.65;
    overflow-wrap: break-word;
    word-break: break-word;
}
.intro-block p strong {
    color: #1a1a1a;
}
.intro-block h3 {
    font-size: clamp(13px, 2.5vw, 15px);
    font-weight: 700;
    margin: 14px 0 0;
    color: #1a1a1a;
}



@media only screen and (max-width: 768px) {
    .sa-places-search-container {
        margin-top: 0;
        margin-left: 0;
    }
    .events-search-container .js-places-filter-form {
        margin-top: 0;
    }
}

/* ============================================================
   PILL FILTER SYSTEM
   ============================================================ */
.events-search-container .filter-section {
    width: 100%;
}
.events-search-container .filter-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}
.events-search-container .filter-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #888;
    white-space: nowrap;
    padding-top: 9px;
    min-width: 72px;
}
.events-search-container .filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    flex: 1;
}
.events-search-container .pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 14px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 400;
    cursor: pointer;
    border: 2px solid #e0e0e0;
    background: #ffffff;
    color: #444;
    transition: all 0.18s ease;
    user-select: none;
    white-space: nowrap;
    line-height: 1;
    font-family: inherit;
    text-decoration: none;
    height: auto;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pill-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 17px;
    height: 17px;
    padding: 0 4px;
    border-radius: 9px;
    font-size: 10px;
    font-weight: 700;
    background: rgba(0, 0, 0, 0.12);
    box-sizing: border-box;
}
.events-search-container .pill.active .pill-count {
    background: rgba(255, 255, 255, 0.25);
}
.events-search-container .pill:hover {
    border-color: #00b4b4;
    color: #00b4b4;
    background: rgba(0, 180, 180, 0.05);
}
.events-search-container .pill.active {
    background: #00b4b4;
    border-color: #00b4b4;
    color: #ffffff;
}
.events-search-container .pill.active:hover {
    background: #009090;
    border-color: #009090;
}
.events-search-container .filter-area-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #e0e0e0;
    flex-wrap: wrap;
    min-width: 0;
}
.events-search-container .filter-area-select {
    appearance: none;
    -webkit-appearance: none;
    background: #ffffff;
    border: 2px solid #e0e0e0;
    border-radius: 100px;
    padding: 7px 34px 7px 14px;
    font-size: 13px;
    line-height: 1;
    font-weight: 400;
    color: #444 !important;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23888' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    transition: border-color 0.18s ease, color 0.18s ease;
    min-width: 150px;
    font-family: inherit;
    height: auto;
}
.events-search-container .filter-area-select:hover {
    border-color: #00b4b4;
    color: #00b4b4 !important;
    background-color: rgba(0, 180, 180, 0.05);
}
.events-search-container .filter-area-select:focus {
    outline: none;
    border-color: #00b4b4;
    box-shadow: 0 0 0 3px rgba(0, 180, 180, 0.15);
}
.filter-results-count {
    margin-left: auto;
    font-size: 12px;
    color: #888;
    font-weight: 500;
    white-space: nowrap;
}
.filter-results-count strong {
    color: #1a1a1a;
}
.events-search-container .filter-area-select option {
    padding: 6px 12px;
    font-size: 13px;
    font-weight: 500;
    color: #444 !important;
    background: #fff !important;
}
.events-search-container .filter-area-select option:hover,
.events-search-container .filter-area-select option:active {
    background: rgba(0, 180, 180, 0.1) !important;
}
.events-search-container .filter-area-select option:checked {
    background: #00b4b4 !important;
    color: #fff !important;
}

@media only screen and (max-width: 768px) {
    .events-search-container .filter-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .events-search-container .filter-label {
        padding-top: 0;
        min-width: unset;
    }
    .events-search-container .filter-area-wrap {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .events-search-container .pill { font-size: 12px; padding: 6px 12px; }
}

/* ============================================================
   PLACE CARDS
   ============================================================ */


.places-list-container {
    order: 2;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    width: 100%;
}


.place-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e0e0e0;
    transition: box-shadow 0.22s ease, transform 0.22s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}
.place-card:hover {
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.16);
    transform: translateY(-3px);
}
.card-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/10;
}
.card-image img {
    width: 100%;
    max-width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.place-card:hover .card-image img { transform: scale(1.04); }
.card-category-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #f5e642;
    color: #1a1a1a;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 3px 9px;
    border-radius: 100px;
    pointer-events: none;
}
.card-body {
    padding: clamp(12px, 2.5vw, 16px) clamp(12px, 2.5vw, 18px) clamp(14px, 2.5vw, 18px);
    flex: 1;
    display: flex;
    flex-direction: column;
}
.card-title {
    font-size: clamp(13px, 2vw, 16px);
    font-weight: 800;
    color: #1a1a1a;
    margin-bottom: 6px;
    line-height: 1.3;
}
.card-excerpt {
    font-size: clamp(12px, 1.8vw, 13.5px);
    color: #666;
    line-height: 1.55;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.card-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid #e0e0e0;
}
.card-link {
    font-size: 11px;
    font-weight: 700;
    color: #00b4b4;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    white-space: nowrap;
    transition: gap 0.15s;
}
.card-link:hover { gap: 6px; }
.card-link svg {
    width: 13px;
    height: 13px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2.5;
}

@media only screen and (max-width: 1048px) {
    .card-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
}
@media only screen and (max-width: 768px) {
    .card-grid { grid-template-columns: 1fr; gap: 14px; }
    .card-excerpt { -webkit-line-clamp: 2; }
}

/* ============================================================
   PAGINATION
   ============================================================ */
.pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 36px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
    flex-wrap: wrap;
    gap: 12px;
}
.pagination-pages {
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
}
.page-btn {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    border: 2px solid #e0e0e0;
    background: #ffffff;
    font-size: 13px;
    font-weight: 600;
    color: #444;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
    text-decoration: none;
    font-family: inherit;
    line-height: 1;
    padding: 0;
    box-sizing: border-box;
}
.page-btn:hover {
    border-color: #00b4b4;
    color: #00b4b4;
}
.page-btn.current {
    background: #00b4b4;
    border-color: #00b4b4;
    color: #ffffff;
    pointer-events: none;
}
.page-btn.current:hover {
    background: #009090;
    border-color: #009090;
    color: #ffffff;
}
.page-btn.ellipsis {
    border: none;
    background: none;
    cursor: default;
    width: auto;
    padding: 0 4px;
    color: #888;
}
.page-btn.ellipsis:hover { color: #888; }
.btn-prev,
.btn-next {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 20px;
    background: #00b4b4;
    color: #ffffff;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: background 0.18s;
    text-decoration: none;
    font-family: inherit;
    line-height: 1;
}
.btn-prev:hover,
.btn-next:hover { background: #009090; }
.btn-prev svg,
.btn-next svg {
    width: 15px;
    height: 15px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2.5;
    flex-shrink: 0;
}

@media only screen and (max-width: 768px) {
    .pagination { justify-content: center; }
    .btn-prev,
    .btn-next { width: 100%; justify-content: center; }
}
@media only screen and (max-width: 380px) {
    .page-btn { width: 32px; height: 32px; font-size: 12px; }
}

/* ============================================================
   LOADING OVERLAY (AJAX filter transitions)
   ============================================================ */
.js-places-results {
    position: relative;
}
.js-places-results.is-loading {
    opacity: 0.4;
    pointer-events: none;
    transition: opacity 0.2s ease;
}
.places-loading-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.5);
    z-index: 5;
    border-radius: 12px;
}
.places-loading-overlay .spinner {
    width: 36px;
    height: 36px;
    border: 3px solid #e0e0e0;
    border-top-color: #00b4b4;
    border-radius: 50%;
    animation: places-spin 0.7s linear infinite;
}
@keyframes places-spin {
    to { transform: rotate(360deg); }
}
