/* ═══════════════════════════════════════════
   com_gcevents — Frontend Styles
   geocaching.sk brand kit
   ═══════════════════════════════════════════ */

.gc-events-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Stats */
.gc-events-stats {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.gc-stat {
    text-align: center;
    padding: 14px 24px;
    background: #fff;
    border-radius: 12px;
    border: 1.5px solid rgba(27,67,50,0.06);
    min-width: 110px;
}

.gc-stat__num {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 26px;
    color: #1B4332;
    line-height: 1;
}

.gc-stat__num--today { color: #FF6B35; }
.gc-stat__num--cito { color: #3A86FF; }

.gc-stat__label {
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #8FA3B0;
    margin-top: 4px;
}

/* Filters */
.gc-events-filters {
    display: flex;
    gap: 16px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    align-items: center;
}

.gc-events-filters__period {
    display: flex;
    gap: 6px;
}

.gc-filter {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 13px;
    padding: 8px 16px;
    border-radius: 8px;
    border: 1.5px solid #D8F3DC;
    background: #fff;
    color: #5D7285;
    text-decoration: none;
    transition: all 0.2s;
}

.gc-filter:hover {
    border-color: #74C69D;
    color: #1B4332;
}

.gc-filter--active {
    background: #1B4332;
    color: #fff;
    border-color: #1B4332;
}

.gc-filter-select {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 13px;
    padding: 8px 12px;
    border-radius: 8px;
    border: 1.5px solid #D8F3DC;
    background: #fff;
    color: #2C3E50;
    cursor: pointer;
}

/* Layout */
.gc-events-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 24px;
    margin-bottom: 48px;
}

/* Event list */
.gc-events-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 750px;
    overflow-y: auto;
    padding-right: 8px;
}

.gc-events-list::-webkit-scrollbar { width: 6px; }
.gc-events-list::-webkit-scrollbar-track { background: #D8F3DC; border-radius: 3px; }
.gc-events-list::-webkit-scrollbar-thumb { background: #74C69D; border-radius: 3px; }

.gc-events-empty {
    text-align: center;
    padding: 48px;
    color: #8FA3B0;
    font-size: 16px;
}

/* Event card */
.gc-event {
    background: #fff;
    border-radius: 14px;
    padding: 16px 20px;
    border: 1.5px solid rgba(27,67,50,0.06);
    display: grid;
    grid-template-columns: 56px 1fr auto;
    gap: 14px;
    align-items: center;
    transition: all 0.2s;
}

.gc-event:hover {
    border-color: #74C69D;
    transform: translateX(4px);
    box-shadow: 0 4px 16px rgba(27,67,50,0.08);
}

.gc-event--today {
    border-color: #FF8C61;
    border-width: 2px;
    background: linear-gradient(135deg, #fff 0%, #FFF8F5 100%);
}

.gc-event--live {
    border-color: #FF6B35;
    border-width: 2px;
    background: linear-gradient(135deg, #fff 0%, #FFF3ED 100%);
    animation: gc-card-pulse 3s ease-in-out infinite;
}

@keyframes gc-card-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255,107,53,0.15); }
    50% { box-shadow: 0 0 0 6px rgba(255,107,53,0); }
}

.gc-event--ended {
    opacity: 0.5;
}

.gc-event--cito {
    border-left: 4px solid #3A86FF;
}

/* Date box */
.gc-event__date-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.gc-event__date {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #D8F3DC;
}

.gc-event--today .gc-event__date,
.gc-event--live .gc-event__date {
    background: #FF6B35;
}

.gc-event__day {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 20px;
    color: #1B4332;
    line-height: 1;
}

.gc-event--today .gc-event__day,
.gc-event--live .gc-event__day { color: #fff; }

.gc-event__month {
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #40916C;
}

.gc-event--today .gc-event__month,
.gc-event--live .gc-event__month { color: rgba(255,255,255,0.8); }

/* ICS download icon */
.gc-event__ics {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    color: #8FA3B0;
    transition: all 0.2s;
    text-decoration: none;
}

.gc-event__ics:hover {
    background: #D8F3DC;
    color: #1B4332;
}

/* Event info */
.gc-event__name {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 2px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.gc-event__name a {
    color: #1B4332;
    text-decoration: none;
}

.gc-event__name a:hover {
    color: #FF6B35;
    text-decoration: underline;
}

.gc-event__meta {
    font-size: 13px;
    color: #5D7285;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Badges */
.gc-badge {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    white-space: nowrap;
    line-height: 1.4;
}

.gc-badge--live {
    background: #FF6B35;
    color: #fff;
    animation: gc-badge-pulse 2s ease-in-out infinite;
}

.gc-badge--today {
    background: #FFF0E8;
    color: #FF6B35;
}

.gc-badge--cito {
    background: rgba(58,134,255,0.12);
    color: #3A86FF;
}

.gc-badge--mega {
    background: rgba(255,107,53,0.12);
    color: #E85D2A;
}

@keyframes gc-badge-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* GC code */
.gc-event__gc {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: #52B788;
    background: #D8F3DC;
    padding: 4px 10px;
    border-radius: 6px;
    white-space: nowrap;
    text-decoration: none;
    align-self: center;
}

.gc-event__gc:hover {
    background: #B7E4C7;
    color: #1B4332;
}

/* Map */
.gc-events-map-wrap {
    border-radius: 16px;
    overflow: hidden;
    border: 1.5px solid rgba(27,67,50,0.06);
    position: sticky;
    top: 80px;
}

#gcEventsMap {
    height: 750px;
}

/* Leaflet popup */
.leaflet-popup-content-wrapper {
    border-radius: 12px !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.12) !important;
}

/* Responsive */
@media (max-width: 900px) {
    .gc-events-layout {
        grid-template-columns: 1fr;
    }

    .gc-events-map-wrap {
        position: static;
    }

    #gcEventsMap { height: 400px; }
    .gc-events-list { max-height: 500px; }
}

@media (max-width: 640px) {
    .gc-event {
        grid-template-columns: 48px 1fr;
        gap: 10px;
    }

    .gc-event__gc { display: none; }
    .gc-event__date { width: 48px; height: 48px; }
    .gc-event__day { font-size: 17px; }
    .gc-events-stats { gap: 8px; }
    .gc-stat { min-width: 80px; padding: 10px 14px; }
}

/* ═══════════════════════════════════════════
   PAGINATION
   ═══════════════════════════════════════════ */
   .gc-events-pagination .pagination .page-item .page-link {
       display: flex;
       align-items: center;
       justify-content: center;
       width: 36px;
       height: 36px;
       border-radius: 8px;
       border: 1.5px solid rgba(27,67,50,0.12);
       background: #fff;
       color: #1B4332;
       font-family: 'Outfit', sans-serif;
       font-weight: 600;
       font-size: 14px;
       text-decoration: none;
       transition: all 0.2s;
   }

   .gc-events-pagination .pagination .page-item .page-link:hover {
       background: #D8F3DC;
       border-color: #52B788;
       color: #1B4332;
   }

   .gc-events-pagination .pagination .page-item.active .page-link {
       background: #1B4332;
       border-color: #1B4332;
       color: #fff;
   }

   .gc-events-pagination .pagination .page-item.disabled .page-link {
       opacity: 0.35;
       cursor: default;
       pointer-events: none;
   }

   .gc-events-pagination {
       margin-top: 24px;
       display: flex;
       flex-direction: column;
       align-items: center;
       gap: 12px;
   }

   .gc-events-pagination .text-end {
       font-size: 13px;
       color: #8FA3B0;
       font-family: 'JetBrains Mono', monospace;
   }

   .gc-events-pagination .pagination {
       display: flex;
       list-style: none;
       gap: 4px;
       margin: 0;
       padding: 0;
   }

.gc-events-pagination span.icon-angle-left::before { content: '‹'; }
.gc-events-pagination span.icon-angle-right::before { content: '›'; }
.gc-events-pagination span.icon-angle-double-left::before { content: '«'; }
.gc-events-pagination span.icon-angle-double-right::before { content: '»'; }

.gc-events-pagination span[class*="icon-angle"] {
     font-size: 18px;
     font-style: normal;
     color: #1B4332;
     line-height: 1;
 }
