.earthquakes-page {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    min-height: 100vh;
    padding: 20px 0 60px;
}

.earthquakes-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.eq-header {
    text-align: center;
    margin-bottom: 24px;
    padding: 20px 24px;
    background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(220, 38, 38, 0.3);
}

.eq-title {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 800;
    color: white;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.eq-subtitle {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
}

/* Main Layout */
.eq-main-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 20px;
    margin-bottom: 24px;
}

@media (max-width: 1100px) {
    .eq-main-grid {
        grid-template-columns: 1fr;
    }
}

/* Map Column */
.eq-map-column {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Map Container */
.map-container {
    background: #0a0a1a;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

#earthquake-map {
    width: 100%;
    height: 500px;
}

/* Detail Panel */
.eq-detail-panel {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.eq-detail-header {
    padding: 16px 20px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15) 0%, rgba(153, 27, 27, 0.15) 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    gap: 16px;
}

.eq-detail-mag {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 800;
    color: white;
    flex-shrink: 0;
}

.eq-detail-info {
    flex: 1;
    min-width: 0;
}

.eq-detail-place {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    color: white;
    margin-bottom: 4px;
}

.eq-detail-time {
    font-size: 0.85rem;
    color: #94a3b8;
}

.eq-detail-usgs-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    background: #ef4444;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    transition: background 0.2s;
    flex-shrink: 0;
}

.eq-detail-usgs-btn:hover {
    background: #dc2626;
}

.eq-detail-body {
    padding: 16px 20px;
}

.eq-detail-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.eq-detail-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 12px 14px;
    border-radius: 10px;
}

.eq-detail-label {
    font-size: 0.7rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 4px;
}

.eq-detail-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: white;
}

@media (max-width: 768px) {
    .eq-detail-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .eq-detail-header {
        flex-wrap: wrap;
    }
    
    .eq-detail-usgs-btn {
        width: 100%;
        justify-content: center;
        margin-top: 8px;
    }
}

.map-controls {
    position: absolute;
    bottom: 16px;
    left: 16px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

.map-btn {
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 8px 14px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s;
    backdrop-filter: blur(10px);
}

.map-btn:hover {
    background: rgba(30, 41, 59, 0.95);
    border-color: rgba(255, 255, 255, 0.3);
}

.map-btn.active {
    background: #ef4444;
    border-color: #ef4444;
}

.map-style-toggle {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 10;
}

/* Sidebar */
.eq-sidebar {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Stats Card */
.eq-stats-card {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-radius: 14px;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.eq-stats-title {
    font-family: var(--font-display);
    font-size: 0.8rem;
    font-weight: 700;
    color: #94a3b8;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.eq-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.eq-stat {
    background: rgba(255, 255, 255, 0.05);
    padding: 12px 10px;
    border-radius: 10px;
    text-align: center;
}

.eq-stat-value {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 800;
    color: white;
}

.eq-stat-label {
    font-size: 0.7rem;
    color: #64748b;
    margin-top: 2px;
}

/* Latest Earthquakes List */
.eq-latest-card {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.eq-latest-header {
    padding: 12px 16px;
    background: rgba(239, 68, 68, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-family: var(--font-display);
    font-size: 0.8rem;
    font-weight: 700;
    color: #ef4444;
    display: flex;
    align-items: center;
    gap: 8px;
}

.eq-latest-list {
    flex: 1;
    overflow-y: auto;
    max-height: 380px;
}

.eq-item {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: all 0.2s;
}

.eq-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.eq-item.active {
    background: rgba(239, 68, 68, 0.15);
    border-left: 3px solid #ef4444;
}

.eq-item.ultimo {
    background: rgba(234, 179, 8, 0.1);
    border-left: 3px solid #eab308;
}

.eq-item-top {
    display: flex;
    align-items: center;
    gap: 10px;
}

.eq-mag {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 800;
    color: white;
    flex-shrink: 0;
}

.eq-item-info {
    flex: 1;
    min-width: 0;
}

.eq-item-place {
    font-size: 0.85rem;
    color: white;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.eq-item-time {
    font-size: 0.7rem;
    color: #64748b;
    margin-top: 2px;
}

.eq-item-badge {
    font-size: 0.6rem;
    padding: 2px 6px;
    border-radius: 4px;
    background: #eab308;
    color: #000;
    font-weight: 700;
    flex-shrink: 0;
}

/* Legend */
.eq-legend {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-radius: 14px;
    padding: 14px 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.eq-legend-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 10px;
}

.eq-legend-items {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.eq-legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.7rem;
    color: #94a3b8;
}

.eq-legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

/* Footer */
.eq-footer {
    text-align: center;
    padding: 16px;
    color: #64748b;
    font-size: 0.8rem;
}

.eq-footer a {
    color: #ef4444;
    text-decoration: none;
}

.eq-footer a:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 1100px) {
    #earthquake-map {
        height: 450px;
    }
    
    .eq-latest-list {
        max-height: 300px;
    }
}

@media (max-width: 768px) {
    .eq-header {
        padding: 16px;
        margin: 0 0 16px 0;
        border-radius: 12px;
    }
    
    .eq-title {
        font-size: 1.4rem;
    }
    
    #earthquake-map {
        height: 350px;
    }
    
    .eq-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .map-controls {
        bottom: 10px;
        left: 10px;
    }
    
    .map-btn {
        padding: 6px 10px;
        font-size: 0.75rem;
    }
}
