/* ============================================================
   Ghost Hunters Map — Globe.GL styles
   ============================================================ */

/* ---------- Globe container ---------- */
.ghm-map {
    width: 100%;
    max-width: 860px;
    aspect-ratio: 1 / 1;
    height: auto !important;
    background-color: transparent;
    position: relative;
    margin-inline: auto;
}

/* ---------- Ghost marker icon ---------- */
@keyframes ghm-marker-pulse {
    0%, 100% { filter: drop-shadow(0 2px 8px rgba(86, 173, 191, 0.55)); }
    50%       { filter: drop-shadow(0 2px 16px rgba(86, 173, 191, 0.9)); }
}

.ghm-marker-icon {
    background: transparent;
    border: none;
    cursor: pointer;
}

.ghm-pulse {
    filter: drop-shadow(0 2px 8px rgba(86, 173, 191, 0.55));
    animation: ghm-marker-pulse 3s ease-in-out infinite;
}

.ghm-marker-icon:hover .ghm-pulse {
    filter: drop-shadow(0 4px 16px rgba(86, 173, 191, 1)) drop-shadow(0 0 24px rgba(86, 173, 191, 0.6));
    animation: none;
}

/* ---------- Popup backdrop ---------- */
.ghm-popup-backdrop {
    position: fixed;
    inset: 0;
    z-index: 99998;
    background: rgba(0, 0, 0, 0.45);
    cursor: default;
}

/* ---------- Popup overlay (modale centrata) ---------- */
.ghm-popup-overlay {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 99999;
    pointer-events: auto;
}

.ghm-popup__inner {
    background-color: #1e1e1e;
    border: 1px solid #3a3a3a;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(86, 173, 191, 0.15);
    color: #f5f5f5;
    padding: 16px;
    min-width: 220px;
    max-width: 280px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
}

.ghm-popup-close {
    position: absolute;
    top: 8px;
    right: 10px;
    background: transparent;
    border: none;
    color: #a0a0a0;
    font-size: 16px;
    cursor: pointer;
    line-height: 1;
    padding: 2px 4px;
}

.ghm-popup-close:hover {
    color: #f5f5f5;
}

.ghm-popup__logo {
    width: 100%;
    max-height: 80px;
    object-fit: cover;
    border-radius: 4px;
}

.ghm-popup__title {
    font-size: 1rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.3;
    margin: 0;
}

.ghm-popup__location {
    font-size: 0.78rem;
    color: #a0a0a0;
    margin: 0;
}

.ghm-popup__excerpt {
    font-size: 0.82rem;
    color: #c8c8c8;
    line-height: 1.5;
    margin: 0;
}

.ghm-popup__equipment {
    font-size: 0.75rem;
    color: var(--color-text-muted, #888);
    margin: 0;
    font-style: italic;
}

.ghm-popup__link {
    display: inline-block;
    font-size: 0.82rem;
    font-weight: 600;
    color: #56adbf;
    text-decoration: none;
    border: 1px solid rgba(86, 173, 191, 0.4);
    border-radius: 4px;
    padding: 4px 10px;
    margin-top: 4px;
    align-self: flex-start;
    transition: background-color 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s;
}

.ghm-popup__link:hover {
    background-color: #56adbf;
    border-color: #56adbf;
    color: #ffffff;
    box-shadow: 0 0 12px rgba(86, 173, 191, 0.5);
}

/* ============================================================
   Map filter panel
   ============================================================ */

.ghm-map-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-sm, 8px);
}

.ghm-map-filters {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--spacing-sm, 8px);
    background-color: var(--color-bg-surface, #1a1a1a);
    border: 1px solid var(--color-border, #333);
    border-radius: var(--radius-md, 8px);
    padding: var(--spacing-sm, 8px) var(--spacing-md, 16px);
    width: 100%;
    max-width: 900px;
}

.ghm-map-filter-group {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs, 4px);
}

.ghm-map-filter-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--color-text-muted, #888);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    white-space: nowrap;
}

.ghm-map-filter-select {
    background-color: var(--color-bg-elevated, #242424);
    border: 1px solid var(--color-border, #333);
    border-radius: var(--radius-sm, 4px);
    color: var(--color-text, #f5f5f5);
    font-size: 0.875rem;
    padding: 0.3rem 0.6rem;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
    min-width: 140px;
}

.ghm-map-filter-select:focus {
    border-color: var(--color-accent, #56adbf);
}

.ghm-map-filter-reset {
    background: transparent;
    border: 1px solid var(--color-border, #333);
    border-radius: var(--radius-sm, 4px);
    color: var(--color-text-muted, #888);
    font-size: 0.78rem;
    padding: 0.3rem 0.75rem;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}

.ghm-map-filter-reset:hover {
    color: var(--color-ghost-white, #f5f5f5);
    border-color: var(--color-accent, #56adbf);
}

.ghm-map-count {
    font-size: 0.78rem;
    color: var(--color-text-muted, #888);
    margin-left: auto;
    display: none;
}

/* ============================================================
   Full-width map page
   ============================================================ */

.ghm-map-page {
    width: 100%;
    padding-inline: var(--spacing-lg, 32px);
}

.ghm-map-page .ghm-map-wrap {
    width: 100%;
}

.ghm-map-page .ghm-map {
    max-width: 960px;
}
