/* Public insights page — card styling (shared base) */

.stats-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
}

.stat-item {
    flex: 1 1 250px;
    min-width: 200px;
    max-width: 320px;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
}

.stat-item h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #00509d;
    margin: 0 0 0.25rem 0;
}

.stat-item p {
    font-size: 0.9rem;
    color: #6c757d;
    margin: 0;
}

.features-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.feature-card {
    flex: 1 1 400px;
    min-width: 300px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    padding: 1.5rem;
}

.feature-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #333;
    margin: 0 0 1rem 0;
}

.feature-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.feature-card ul li {
    padding: 0.4rem 0;
    color: #555;
    font-size: 0.95rem;
}

/* Chart cards (country pie charts + state bar charts) */
.chart-card {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    padding: 1.5rem;
    text-align: center;
}

.chart-card-country {
    width: 240px;
}

.chart-card h3 {
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 0.75rem;
    color: #333;
}

.chart-card-state h3 {
    margin-bottom: 0.5rem;
}

.chart-card-state p.contractor-count {
    color: #888;
    font-size: 0.8rem;
    margin-bottom: 0.75rem;
}

.chart-card p.contractor-count {
    color: #555;
    font-size: 0.85rem;
    margin-bottom: 0;
}

.chart-card .chart-canvas-wrapper {
    position: relative;
}

.chart-card-country .chart-canvas-wrapper {
    width: 180px;
    height: 180px;
    margin: 0 auto 0.75rem;
}

.chart-card-state .chart-canvas-wrapper {
    height: 220px;
}

/* Hover: kill all card hover effects */
.stat-item:hover,
.feature-card:hover,
.chart-card:hover,
.stat-item:hover *,
.feature-card:hover *,
.chart-card:hover * {
    transform: none !important;
    box-shadow: none !important;
    transition: none !important;
    cursor: default !important;
}

@media (max-width: 768px) {
    .stat-item {
        flex: 1 1 100%;
        max-width: 100%;
    }
    .feature-card {
        flex: 1 1 100%;
    }
    .stats-grid,
    .features-grid {
        gap: 1rem;
    }
    .chart-card-country {
        width: 100%;
        max-width: 320px;
    }
}

/* SIMPLIFIED CSS - Levels.fyi inspired styling for state cards */
.levels-style-container {
    margin-bottom: 2rem;
}

.company-section {
    margin-bottom: 1.5rem;
}

.company-header-row {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e9ecef;
}

.company-name {
    font-weight: 800;
    font-size: 1rem;
    color: #333;
    margin-right: 0.75rem;
    /* Removed: text-transform: uppercase; */
    /* Removed: letter-spacing: 0.5px; */
}

.company-total-badge,
.company-section .company-total-badge,
.levels-style-container .company-total-badge,
.company-amazon .company-total-badge,
.company-fedex .company-total-badge,
.company-usps .company-total-badge,
.company-dpd .company-total-badge,
.company-dhl .company-total-badge,
.company-doordash .company-total-badge {
    font-weight: 700;
    font-size: 0.8rem;
    color: #686c6d;
    background: rgba(0, 0, 0, 0.05);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

/* State pills - like Levels.fyi salary cards */
.state-pills-container {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 0.5rem !important;
}

.state-pill {
    display: inline-flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: 80px !important;
    max-width: 100px !important; /* Prevent pills from getting too wide on desktop */
    flex: 1 1 auto !important; /* Allow pills to grow and shrink */
    padding: 0.75rem 0.5rem !important;
    border-radius: 8px !important;
    background: linear-gradient(rgb(255, 255, 255), rgba(0, 0, 0, 0.03) 300%) !important;
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
}

.state-pill-name {
    font-weight: 700 !important;
    font-size: 0.85rem !important;
    color: #333 !important;
    margin-bottom: 0.25rem !important;
    text-align: center !important;
}

.state-pill-count,
.company-section .state-pill-count,
.levels-style-container .state-pill-count,
.company-amazon .state-pill-count,
.company-fedex .state-pill-count,
.company-usps .state-pill-count,
.company-dpd .state-pill-count,
.company-dhl .state-pill-count,
.company-doordash .state-pill-count {
    font-weight: 800 !important;
    font-size: 1rem !important;
    color: #686c6d !important;
    text-align: center !important;
}

/* Company-specific colors - removed, using single color #686c6d for all numbers */

/* Responsive adjustments - Stack pills vertically on mobile */
@media (max-width: 768px) {
    .state-pills-container {
        flex-direction: column !important;
        gap: 0.5rem !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    .state-pill {
        width: 100% !important;
        min-width: 0 !important; /* Override any minimum width */
        max-width: 100% !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        padding: 0.75rem 1rem !important;
        border-radius: 8px !important;
        box-sizing: border-box !important; /* Include padding in width calculation */
    }
    
    .state-pill-name {
        font-size: 0.9rem !important;
        margin-bottom: 0 !important;
        text-align: left !important;
        flex: 1 1 auto !important; /* Allow text to shrink if needed */
        min-width: 0 !important; /* Allow text to shrink below content size */
        overflow-wrap: break-word !important; /* Break long words */
        word-break: break-word !important;
    }
    
    .state-pill-count {
        font-size: 1rem !important;
        font-weight: 800 !important;
        flex-shrink: 0 !important; /* Don't shrink the count */
        margin-left: 0.5rem !important; /* Space between name and count */
    }
}

/* Extra small devices */
@media (max-width: 576px) {
    .state-pill {
        padding: 0.6rem 0.75rem !important;
    }
    
    .state-pill-name {
        font-size: 0.85rem !important;
    }
    
    .state-pill-count {
        font-size: 0.95rem !important;
    }
    
    .company-name {
        font-size: 0.9rem !important;
    }
    
    .company-total-badge {
        font-size: 0.75rem !important;
        padding: 0.2rem 0.4rem !important;
    }
    
    /* Ensure no horizontal scrolling on very small screens */
    .levels-style-container {
        overflow-x: hidden !important; /* Prevent horizontal scroll */
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    .state-pills-container {
        margin-left: -0.25rem !important;
        margin-right: -0.25rem !important;
        padding-left: 0.25rem !important;
        padding-right: 0.25rem !important;
    }
}

/* Card styling to match state-pill aesthetic */
.card {
    border-radius: 8px !important;
    background: linear-gradient(rgb(255, 255, 255), rgba(0, 0, 0, 0.03) 300%) !important;
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
    box-shadow: none !important;
}

/* Card body padding adjustment */
.card-body {
    padding: 1.25rem !important;
}

/* Metric cards inside cards */
.metric-card {
    border-radius: 8px !important;
    background: linear-gradient(rgb(255, 255, 255), rgba(0, 0, 0, 0.03) 300%) !important;
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
}

/* Card title styling - at top of card body */
.card-title-top {
    margin-top: 0;
    margin-bottom: 1rem;
    padding-bottom: 0 !important;
    border-bottom: none !important;
    font-size: 1rem;
    font-weight: 700 !important;
    line-height: 1.2;
    text-transform: none !important;
    letter-spacing: normal !important;
}

/* Color classes for titles - all #333, no borders */
.title-primary {
    color: #333;
    border-bottom: none;
    font-weight: 800 !important;
}

.title-warning {
    color: #333;
    border-bottom: none;
    font-weight: 800 !important;
}

.title-info {
    color: #333;
    border-bottom: none;
    font-weight: 800 !important;
}

.title-light {
    color: #333;
    border-bottom: none;
    font-weight: 800 !important;
}

.title-success {
    color: #333;
    border-bottom: none;
    font-weight: 800 !important;
}

.title-teal {
    color: #333;
    border-bottom: none;
    font-weight: 800 !important;
}

/* Recent company pills styling */
.recent-companies-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.recent-company-pill {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 80px;
    padding: 0.75rem 0.5rem;
    border-radius: 8px;
    background: linear-gradient(rgb(255, 255, 255), rgba(0, 0, 0, 0.03) 300%);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

/* Explicitly remove any hover effects */
.recent-company-pill:hover,
.recent-company-pill:focus,
.recent-company-pill:active {
    transform: none !important;
    box-shadow: none !important;
    background: linear-gradient(rgb(255, 255, 255), rgba(0, 0, 0, 0.03) 300%) !important;
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
    cursor: default !important;
}

.recent-company-name {
    font-weight: 700;
    font-size: 0.85rem;
    color: #333;
    margin-bottom: 0.25rem;
    text-align: center;
}

.recent-company-count {
    font-weight: 800;
    font-size: 1rem;
    color: #686c6d;
    text-align: center;
}

/* Company-specific colors for recent pills - removed, using single color #686c6d for all numbers */

/* Location networks styling */
.bg-purple {
    background-color: #4d148c !important;
    color: white !important;
}

.btn-outline-purple {
    color: #4d148c !important;
    border-color: #4d148c !important;
}

.btn-outline-purple:hover {
    background-color: #4d148c !important;
    color: white !important;
}

.text-purple {
    color: #4d148c !important;
}

/* Responsive adjustments for recent pills - matching state pills */
@media (max-width: 768px) {
    .recent-company-pill {
        min-width: 70px !important;
        padding: 0.5rem 0.25rem !important;
    }
    
    .recent-company-name {
        font-size: 0.8rem !important;
    }
    
    .recent-company-count {
        font-size: 0.9rem !important;
    }
    
    /* Chart adjustments for mobile */
    .chart-container {
        height: 180px !important;
    }
}

/* Make all bold/strong text extra bold */
strong,
b {
    font-weight: 800 !important;
}

/* Export links styling */
.export-links {
    margin-top: 0.25rem;
}

.export-link {
    display: inline-block;
    color: #00509d;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    line-height: 1.3;
    border-bottom: 1px solid transparent;
    transition: color 0.2s ease, border-bottom-color 0.2s ease;
}

.export-link:hover {
    color: #00509d;
    text-decoration: none;
    border-bottom: 1px solid #00509d;
}

.export-link-primary {
    font-weight: 700;
    color: #00509d;
    font-size: 0.95rem;
}

.export-link-primary:hover {
    color: #00509d;
    text-decoration: none;
    border-bottom: 1px solid #00509d;
}

/* Enhanced progress bars for contact completeness */
.completeness-container .progress {
    height: 12px !important;
    border-radius: 6px !important;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1) !important;
}

.completeness-container .progress-bar {
    border-radius: 6px !important;
    box-shadow: 0 2px 4px rgba(90, 98, 104, 0.2) !important;
    transition: width 0.6s ease !important;
}

/* Hover effect for progress bars */
.completeness-item:hover .progress-bar {
    box-shadow: 0 2px 8px rgba(90, 98, 104, 0.3) !important;
}

/* Company Map Tooltips */
.company-map-tooltip {
    position: absolute;
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 8px 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    z-index: 1000;
    min-width: 120px;
    pointer-events: none;
    font-size: 12px;
    line-height: 1.4;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translate(-50%, -110%); }
    to { opacity: 1; transform: translate(-50%, -120%); }
}

/* CSS arrows removed - now handled dynamically by JavaScript */

/* Company map container positioning */
.company-map-container {
    position: relative;
}

/* Ensure tooltips appear above other elements */
.company-map-container svg {
    z-index: 1;
    position: relative;
}
