/* ============================================
   COMPARISON & GHOST ALERTS COMPONENT
   Comparison bar and ghost ship alerts
   ============================================ */

/* Comparison Bar */
.comparison-bar {
    position: fixed;
    bottom: 80px;
    left: 0;
    right: 0;
    background: var(--color-bg-elevated);
    border-top: 2px solid var(--color-accent);
    padding: var(--space-3);
    z-index: 100;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.3);
    display: none;
}

.comparison-bar.visible {
    display: block;
}

.comparison-bar__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-2);
}

.comparison-bar__toggle {
    background: none;
    border: none;
    color: var(--color-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    padding: var(--space-2);
}

.comparison-bar__count {
    background: var(--color-accent);
    color: white;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 12px;
    min-width: 24px;
    text-align: center;
}

.comparison-bar__label {
    color: var(--color-text-secondary);
}

.comparison-bar__chevron {
    transition: transform 0.2s;
}

.comparison-bar__chevron.expanded {
    transform: rotate(180deg);
}

.comparison-bar__clear {
    background: transparent;
    border: 1px solid var(--color-border);
    color: var(--color-text-secondary);
    padding: var(--space-1) var(--space-3);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: var(--text-xs);
}

.comparison-bar__clear:hover {
    background: var(--color-bg-hover);
    border-color: var(--color-text-muted);
}

.comparison-bar__items {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
    min-height: 32px;
}

.comparison-bar__placeholder {
    color: var(--color-text-muted);
    font-size: var(--text-xs);
    font-style: italic;
}

/* Comparison Chip */
.comparison-chip {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    background: var(--color-bg-hover);
    border: 1px solid var(--color-border);
    padding: var(--space-1) var(--space-2);
    border-radius: var(--radius-md);
    font-size: var(--text-xs);
}

.comparison-chip__type {
    font-size: 12px;
}

.comparison-chip__name {
    font-weight: 600;
    color: var(--color-text);
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.comparison-chip__remove {
    background: none;
    border: none;
    color: var(--color-text-muted);
    cursor: pointer;
    padding: 2px;
    font-size: 12px;
}

.comparison-chip__remove:hover {
    color: var(--color-danger);
}

/* Ghost Ship Alert */
.ghost-alert {
    position: fixed;
    top: 52px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #7c3aed, #5b21b6);
    border: 1px solid #8b5cf6;
    border-radius: var(--radius-lg);
    padding: var(--space-3) var(--space-4);
    display: flex;
    align-items: center;
    gap: var(--space-3);
    z-index: var(--z-overlay);
    box-shadow: var(--shadow-lg);
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.ghost-alert.hidden {
    display: none;
}

.ghost-alert__icon {
    font-size: 24px;
}

.ghost-alert__text {
    color: white;
    font-size: var(--text-sm);
}

.ghost-alert__text strong {
    font-weight: 700;
}

.ghost-alert__action {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: var(--space-1) var(--space-3);
    border-radius: var(--radius-md);
    font-size: var(--text-xs);
    font-weight: 600;
    cursor: pointer;
    transition: background var(--duration-fast);
}

.ghost-alert__action:hover {
    background: rgba(255, 255, 255, 0.3);
}

.ghost-alert__close {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    transition: background var(--duration-fast);
}

.ghost-alert__close:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Ghost Marker */
.ghost-marker {
    background: transparent;
}

.ghost-marker-pulse {
    width: 30px;
    height: 30px;
    border: 2px solid #8b5cf6;
    border-radius: 50%;
    animation: ghostPulse 2s infinite;
}

@keyframes ghostPulse {
    0% {
        transform: scale(0.5);
        opacity: 1;
    }
    100% {
        transform: scale(2);
        opacity: 0;
    }
}

.ghost-tooltip {
    background: #1a1a1a;
    border: 1px solid #8b5cf6;
    border-radius: var(--radius-md);
    padding: var(--space-2);
    color: #e5e5e5;
    font-size: 12px;
}
